-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathchars.cpp
More file actions
28 lines (24 loc) · 900 Bytes
/
Copy pathchars.cpp
File metadata and controls
28 lines (24 loc) · 900 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
#include <iostream>
int main(){
int x {5};
std::cout << "The value of x is: " << x << '\n';
std::cout << "First part\tSecond part\n";
std::cout << "Please enter a keyboard character: ";
char ch{};
std::cin.get(ch);
std::cout << "You entered: " << ch << "\n";
std::cin.get(ch);
std::cout << "You entered: " << ch << '\n';
std::cout << "This prints a single quote \' \n";
std::cout << "This prints a double quote \" \n";
std::cout << "This is a vertical tab \v";
std::cout << "This is an alert \a";
std::cout << "\nYou can clearly see what the vertical tab did there\n";
std::cout << "\"This is quoted text\"\n";
std::cout << "This string contains a single backslash \\\n";
std::cout << "6F in hex is char '\x6F'\n";
int y { 5 };
// std::cout << "The value of x is " << y << '!\n'; // added exclamation point (it won't compile)
std::cin.get();
return 0;
}