i am getting a blank out put on this program i dont know why t got these massage when i go debbuging.
'computerprogrammin13.exe': Loaded 'C:\Users\neha\Documents\Visual Studio 2010\Projects\computerprogrammin13\Debug\computerprogrammin13.exe', Symbols loaded.
'computerprogrammin13.exe': Loaded 'C:\Windows\SysWOW64\ntdll.dll', Cannot find or open the PDB file
'computerprogrammin13.exe': Loaded 'C:\Windows\SysWOW64\kernel32.dll', Cannot find or open the PDB file
'computerprogrammin13.exe': Loaded 'C:\Windows\SysWOW64\KernelBase.dll', Cannot find or open the PDB file
'computerprogrammin13.exe': Loaded 'C:\Windows\SysWOW64\msvcp100d.dll', Symbols loaded.
'computerprogrammin13.exe': Loaded 'C:\Windows\SysWOW64\msvcr100d.dll', Symbols loaded.
The program '[6572] computerprogrammin13.exe: Native' has exited with code 0 (0x0).
this is my code that i write i dont kn ow what i did was wrong
It just cannot find a few program database files that aren't strictly related to your program.
Your program actually runs fine; it has an exit code of 0.
Edit: If you're looking for console output there won't be any. If you want to output to the console, you need to use the cout command. Does your output file get created?
i find the file but when i open it it do the same ,, i have a question if i send this .cpp file to my teacher can she be able to look the output i try every thing theri is no error but i am not getting output
I am a lil confuse wrt that if condition with the factorial but what is meant by including the entire path is to find the location copy and paste what you see at the top of the address bar and put a / then your file name.
As ui uiho pointed out it should look like this /Users/home/Desktop/projects/filename.filetype
'computerprogrammin13.exe': Loaded 'C:\Users\neha\Documents\Visual Studio 2010\Projects\computerprogrammin13\Debug\computerprogrammin13.exe', Symbols loaded.
'computerprogrammin13.exe': Loaded 'C:\Windows\SysWOW64\ntdll.dll', Cannot find or open the PDB file
'computerprogrammin13.exe': Loaded 'C:\Windows\SysWOW64\kernel32.dll', Cannot find or open the PDB file
'computerprogrammin13.exe': Loaded 'C:\Windows\SysWOW64\KernelBase.dll', Cannot find or open the PDB file
'computerprogrammin13.exe': Loaded 'C:\Windows\SysWOW64\msvcp100d.dll', Symbols loaded.
'computerprogrammin13.exe': Loaded 'C:\Windows\SysWOW64\msvcr100d.dll', Symbols loaded.
The program '[1556] computerprogrammin13.exe: Native' has exited with code 0 (0x0).
get this when i debug it
and i also try to put all of the folderpath
i get the same debug answer
when you allocate a file the compiler searches for a file relative to the location of the programs location. sometimes the compiler looks in the wrong location or the program gets moved away from the original file location. including the full file path(absolute location) tells the compiler EXACTLY where to locate the file. remember that if a file is not allocated the compiler is placing the pointer somewhere in your RAM, and you will not be able to get any information form the file. if you include the absolute location then the only possible way for the file pointer to be pointing to nothing is if the file does NOT exist. if you only include the relative path there are several possibilities on why the correct file is not being allocated. so i am telling you to use the absolute path because if that does not work the file must not exist or your compiler cannot access files.
I see you still haven't taken ui uiho advice.
Let me help you.
Copy the file from where ever it is and place it in your My Documents.
Next replace the 5th line in your main which says infile.open("computerprogrammin13.txt");
with
infile.open("C:\Users\System User\Documents\computerprogrammin13.txt");
it should work hopefully