0_0_27034261_11443.cpp:2:11: error: '::main' must return 'int' void main() ^ 0_0_27034261_11443.cpp: In function 'int main()': 0_0_27034261_11443.cpp:5:18: error: 'scanf_s' was not declared in this scope scanf_s("%d", &M); ^