Answer:
The answer to the following code is "40".
Explanation:
In the question there are two variable is given that is discountAmount and orderTotal. In the orderTotal variable, we assign a value that is 200. Then we use the if...else Ladder conditional statement. In this statement, we use the if block in the if block we check condition that if orderTotal variable value is greater then 200. we calculate the 3 percent of orderTotal and put the value in the discountAmount. In the else-if block, we check that if orderTotal variable value is greater then 100. then we calculate the 2 percent of orderTotal that is 40 and put the value in the discountAmount. In the else part we calculate the 1 percent of orderTotal and put the value in the discountAmount. So the answer to this question is "40".
I’m pretty positive that it is Text!
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.
Answer:
D. Hot site.
Explanation:
A hot site is a backup site which is always running.A hot site lets a company to continue it's normal operations within a very short period of time and in case of power outrage or disaster that could impair the computer hardware's ability to work as designed.
Hence the answer to this question is Hot site option d.