How to learn c language that comes with win10 linux system --- solve the problem using gdb

  1.windos store---ubuntu18

2. Installation source change

3 can be installed gcc apt-install 

4 can be installed gdb apt-instll

5. Write helloworld

Denoted 1.c file

 

#include <stdio.h>

int main ()

{

printf("Hello World!\n");

return 0;

}

6. gcc -g 1.c -g parameter which indicates that the debugging turned on

7. gdb -tui

After entering the file a.out

 

Guess you like

Origin www.cnblogs.com/zhangbo2008/p/11349581.html