Home / Expert Answers / Electrical Engineering / lab-1-type-the-following-mathrm-c-programs-using-visual-studio-or-any-ide-that-you-us-pa160

(Solved): Lab: 1. Type the following \( \mathrm{C}++ \) programs using visual studio or any IDE that you us ...



Lab:
1. Type the following \( \mathrm{C}++ \) programs using visual studio or any IDE that you use and observe the output
a).

c) using tab space: \( I t \)
\#include < iostream \( > \)
using namespace std;
int main()
\{
cout \( \ll \) |t|t|t My first

Lab: 1. Type the following \( \mathrm{C}++ \) programs using visual studio or any IDE that you use and observe the output a). b) Using newline command : endl #include < iostream \( > \) using namespace std; int main() \{ cout \( \ll \) "My first \( \mathrm{C}++ \) program." \( \ll \) endl; cout \( \ll \) "The sum of 2 and \( 3=" \ll 5 \ll \) endl; cout \( \ll \) " \( 7+8=" \ll 7+8 \ll \) endl; return 0 3 Notice that the endl command at the end of statement forces a newline. c) using tab space: \( I t \) \#include < iostream \( > \) using namespace std; int main() \{ cout \( \ll \) "|t|t|t My first \( \mathrm{C}++ \) program." \( \ll \) endl; cout \( \ll \) "The sum of 2 and \( 3=" \ll 5 \ll \) endl; cout \( \ll " 7+8=" \ll 7+8 \ll \) endl; return 0 ; \} 2. Write a \( \mathrm{C}++ \) program to display following information in the monitor Your name (First, last), age , and Academic level (Freshman, Junior....etc). The output should looks like John, William 20 Freshman


We have an Answer from Expert

View Expert Answer

Expert Answer


a) My first C++ program.The sum of 2 and 3=57+8=15 b) My first C++ pr
We have an Answer from Expert

Buy This Answer $5

Place Order

We Provide Services Across The Globe