Answer:
The ouput of the given code is :
22
is "Tom's age.
Explanation:
Here in this code the variable user_name and user_age are initialized to "Tom" and 22 respectively as statement is given in the question i.e cout << user_age << " \nis " + user_name << "'s age.";.This line will print the user_age i.e 22 after that the control moves to the next line and print is "Tom's age.
Following are the code in c++
#include <iostream> // header file
#include <string>
using namespace std;
int main() // main function
{
string user_name="Tom";
int user_age= 22;
cout << user_age << " \nis " + user_name << "'s age.";
return 0;
}
Output:
22
is "Tom's age.
Answer:
home page (also written as homepage) is the main web page of a website.
Ans 2
Answer:
#include <bits/stdc++.h>
using namespace std;
bool isPrime(int n)
{
for(int j=2;j<=n-1;j++) //loop to check prime..
{
if(n%j==0)
return false;
}
return true;
}
int main(){
int n;
cout<<"Enter the integer"<<endl;//taking input..
cin>>n;
if(isPrime(n))//printing the message.
{
cout<<"The number you have entered is prime"<<endl;
}
else
{
cout<<"The number is not prime"<<endl;
}
return 0;
}
Output:-
Enter the integer
13
The number you have entered is prime
Explanation:
The above written program is in C++.I have created a function called isPrime with an argument n.I have used a for loop to check if the number is prime or not.In the main function I have called the function isPrime for checking the number is prime or not.
BMP (Bitmap). I may be wrong. I'm sorry.
Answer:
if(i>1)
{
Console.WriteLine(i*i);
Console.WriteLine(i*i*i);
}
Explanation:
This is written in C#, and it's probably not as clean as it could be. I'm not sure what language you wanted it in, so I just picked the one I'm most familiar with.