23rd Feb 2023, 3:02 AM
LÆ°ÆĄng Trung Hiáșżu
LÆ°ÆĄng Trung Hiáșżu - avatar
1 Answer
+ 4
LÆ°ÆĄng Trung Hiáșżu I see two problems that prevent it from compiling and running. The scanf arguments in line 6 are all inside the format string. Change from this: scanf("%d%d%d,&KT,&GK,&CK"); To this: scanf("%d%d%d", &KT,&GK,&CK); Also, line 4 and line 9 have duplicate declarations for variable TB. Remove line 4. That should allow the program to run. I am unclear whether the logic does what you intend. Let us know if you need further help.
23rd Feb 2023, 4:02 AM
Brian
Brian - avatar