DEV Community πŸ‘©β€πŸ’»πŸ‘¨β€πŸ’»

DEV Community πŸ‘©β€πŸ’»πŸ‘¨β€πŸ’» is a community of 970,177 amazing developers

We're a place where coders share, stay up-to-date and grow their careers.

Create account Log in
C++
C++

Posted on

Variable in C++

include

using namespace std;

int main()
{
char examGrade = 'a';
int myRollNumber = 139;
float gravitational_acceleration_on_earth = 9.8; // meter per second
double gravitational_acceleration_on_other_planet = 0.0058;
bool is_cpp_faster_oop_language = true;

cout << "Exam Grade : " << examGrade << endl;
cout << "My Rollnumber : " << myRollNumber << endl;
cout << "Gravitational Acceleration on Earth : " << gravitational_acceleration_on_earth << " Meter per Second" << endl;
cout << "Gravitational Acceleration On Other Planet : " << gravitational_acceleration_on_other_planet << " meter Per Second" << endl;
cout << "is C++ Faster Object Oriented Language ? " << is_cpp_faster_oop_language << endl;
return 0;
Enter fullscreen mode Exit fullscreen mode

}

Top comments (0)

🌚 Friends don't let friends browse without dark mode.

Sorry, it's true.