鱼C论坛

 找回密码
 立即注册
查看: 1574|回复: 2

[已解决]求助

[复制链接]
发表于 2021-11-29 23:06:50 | 显示全部楼层    本楼为最佳答案   
       现在再试
  1. #include <stdio.h>
  2. #include <string.h>

  3. int main()
  4. {
  5.         char str1[] = "love";
  6.         char str2[] = "FishC";

  7.         if (strlen(str1) - strlen(str2) < 0)
  8.         {
  9.                 printf("字符串 %s 比字符串 %s 短!\n" , str1 , str2);
  10.         }
  11.         else
  12.         {
  13.                 printf("字符串 %s 比字符串 %s 长!\n" , str1 , str2);
  14.         }

  15.         return 0;
  16. }
复制代码
小甲鱼最新课程 -> https://ilovefishc.com
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

小黑屋|手机版|Archiver|鱼C工作室 ( 粤ICP备18085999号-1 | 粤公网安备 44051102000585号)

GMT+8, 2026-4-2 05:23

Powered by Discuz! X3.4

© 2001-2023 Discuz! Team.

快速回复 返回顶部 返回列表