Jul 29, 2015 at 6:40pm UTC
So I Get this error:
o- no such file or directory
vars.exe no such file or directory
what i wrote in command prompt is c++ vars.cpp o- vars.exe
here is the code for vars.cpp
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22
#include <iostream>
using namespace std ;
// ****SOFTWARECODE STARTS HERE*****//
int main()
{
//program code goes here
char letter ; //Declared then Initialized
int number ; //Declared then Initialized
float decimal = 7.5 ; //Declared and initialized
double pi = 3.14159 //Declared and initialized
bool isTrue = false //Declared and initialized
return 0 ;
count << "char letter:" << letter << endl ;
count << "int number:" << number << endl ;
count << "float decimal:" << decimal << endl ;
count << "double pi:" << pi << endl ;
count << "bool isTrue" << isTrue << endl ;
// ****SOFTWARECODE STOPS HERE****//
}
Last edited on Jul 29, 2015 at 6:41pm UTC
Jul 29, 2015 at 7:48pm UTC
Can You Explain That to Me? Im So sorry Im Beginner
Jul 29, 2015 at 7:51pm UTC
Read the C++ Language Tutorial, http://www.cplusplus.com/doc/tutorial/.
Jul 29, 2015 at 8:05pm UTC
I don't know about your compiler error but it seems like you entered your return statement before the code that you wanted to output. You also misspelled "cout" as count.
Jul 29, 2015 at 8:11pm UTC
Should you have -o instead of o- ?