面部表情凝重 发表于 2020-1-31 19:09:11

作为一个当代大学生,我太难了

收心625 发表于 2020-1-31 19:25:07

加油加油

newlife 发表于 2020-1-31 19:30:10

感谢老师

lzb0727 发表于 2020-1-31 19:50:06

小白太难了

小峰峰_ 发表于 2020-1-31 21:15:53

来啦

anguanping 发表于 2020-1-31 22:08:09

TUYISHIZHIKUAI

yyyyyellow 发表于 2020-1-31 22:49:30

1

江刘儿96 发表于 2020-1-31 22:51:48

谢谢

pikachu2333 发表于 2020-1-31 23:00:02


#include <io.h>
#include <direct.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>

#define MAX      256

long total;

int countLines(const char *filename);
void findAllCodes(const char *path);
void findALLFiles(const char *path);

int countLines(const char *filename)
{
      FILE *fp;
      int count = 0;
      int temp;
      
      if ((fp = fopen(filename, "r")) == NULL)
      {
                fprintf(stderr, "Can not open the file:%s\n", filename);
                return 0;
      }
      
      while ((temp = fgetc(fp)) != EOF)
      {
                if (temp == '\n')
                {
                        count++;
                }
      }
      
      fclose(fp);
      
      return count;
}

void findAllCodes(const char *path)
{
      struct _finddata_t fa;
      long handle;
      char thePath, target;
      
      strcpy(thePath, path);
      if((handle = _findfirst(strcat(thePath, "/*.c"), &fa)) != -1L)

15927504329 发表于 2020-1-31 23:12:31

0:因为机算机只认识0和1
1:机器语言
2:编译吧,但我怎么记得的是“把源代码直接翻译成机器语言”而不是汇编语言
3:编译产生目标文件,解释不产生
4:C语言的可移植性高,源代码在只需要改动很少甚至不用改动的情况下就能直接跨平台运行
5:将源代码先转换为中间代码,再由解释器翻译,之后交给cpu执行
6:查。。。表?
7:亲们,趁敌人吃饭时发动进攻

冯小川 发表于 2020-1-31 23:18:55

#include<stdio.h>
int main()
{
printf("hello world");
return 0;
}

鱼C_小坏蛋 发表于 2020-1-31 23:57:42

答案

han.. 发表于 2020-2-1 00:17:37

1

MoleAA 发表于 2020-2-1 08:55:30

加油学习!

degulas 发表于 2020-2-1 09:56:31

0.只能读懂二进制的0和1
1,机器码
2,编译
3,是否直接转化为机器语言
4,不一定,可能稍加修改
5,字节码是通用的
6,将英文字母用符号代替
7太难了

2646810570@qq.c 发表于 2020-2-1 11:32:07

.

樊祥柄 发表于 2020-2-1 11:42:25

想看

MUMUmumu- 发表于 2020-2-1 11:47:24

1

D-小妍 发表于 2020-2-1 12:44:12

来啦

kongmu 发表于 2020-2-1 14:16:12

666
页: 527 528 529 530 531 532 533 534 535 536 [537] 538 539 540 541 542 543 544 545 546
查看完整版本: S1E2:第一个程序 | 课后测试题及答案