Problems with debugging in visual studio 2015 in C language

0

I made this program:

#include <stdio.h>

int main()
{
    printf("Aula de C.\n");

    return 0;

}

When I load ctrl + f5 or f5 I wait for the terminal to open and stay static to show me the program result. What happens is the terminal open and then close without having time to see the sentence written in the code.

In the debug output this appears to me:

'Project2.exe' (Win32): Loaded 'C:\Users\Wilson\Documents\Visual Studio 2015\Projects\Project2\Debug\Project2.exe'. Symbols loaded.
'Project2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\ntdll.dll'. Cannot find or open the PDB file.
'Project2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\kernel32.dll'. Cannot find or open the PDB file.
'Project2.exe' (Win32): Unloaded 'C:\Windows\SysWOW64\kernel32.dll'
'Project2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\kernel32.dll'. Cannot find or open the PDB file.
'Project2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\KernelBase.dll'. Cannot find or open the PDB file.
'Project2.exe' (Win32): Loaded 'C:\Program Files\Norton Security\NortonData.9.3.13\Definitions\BASHDefs170726.001\UMEngx86.dll'. Cannot find or open the PDB file.
'Project2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\vcruntime140d.dll'. Cannot find or open the PDB file.
'Project2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\ucrtbased.dll'. Cannot find or open the PDB file.
'Project2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\ucrtbased.dll'. Cannot find or open the PDB file.
'Project2.exe' (Win32): Unloaded 'C:\Windows\SysWOW64\ucrtbased.dll'
'Project2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\kernel.appcore.dll'. Cannot find or open the PDB file.
'Project2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\msvcrt.dll'. Cannot find or open the PDB file.
'Project2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\rpcrt4.dll'. Cannot find or open the PDB file.
'Project2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\sspicli.dll'. Cannot find or open the PDB file.
'Project2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\cryptbase.dll'. Cannot find or open the PDB file.
'Project2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\bcryptprimitives.dll'. Cannot find or open the PDB file.
'Project2.exe' (Win32): Loaded 'C:\Windows\SysWOW64\sechost.dll'. Cannot find or open the PDB file.
The thread 0x1200 has exited with code 0 (0x0).
The thread 0x3c68 has exited with code 0 (0x0).
The thread 0x22bc has exited with code 0 (0x0).
The thread 0x2170 has exited with code 0 (0x0).
The program '[8736] Project2.exe' has exited with code 0 (0x0).

Thanks in advance to anyone who tries to help me.

    
asked by anonymous 31.07.2017 / 19:05

2 answers

0

Your code is running and closed .. if you want to see the output put a scanf or System("pause"); ; D

    
02.08.2017 / 16:05
0

Read your program: it will print a string on the screen, and shortly thereafter, it will return 0, ie it will EXIT the program by returning EXIT_SUCCESS. In C, every program automatically closes after its execution, but you can work around this with system ("wait"); or just a getch ();.

    
29.10.2018 / 12:13