Answer:
The C# code is given below
Explanation:
using System;
public class SwimmingWaterTemperatur
{
public static void Main()
{
while(true){
Console.Write("\nPlease enter the water temperature : ");
int x = Int32.Parse (Console.ReadLine());
try{
if(CheckComfort(x)){
Console.Write(x+" degrees is comfortable for swimming.");
}else{
Console.Write(x+" degrees is not comfortable for swimming.");
}
}catch(Exception ex){
Console.WriteLine(ex);
}
}
}
public static Boolean CheckComfort(int temp){
if(temp>=70 && temp<=85){
return true;
}else if(temp>=32 && temp<=212){
return false;
}else{
throw new ArgumentException("Value does not fall within the exptected range.");
}
}
}
Every program has minimum system requirement, so at least His CPU is not good, or the amount of his RAM is too short to run the new version of OS.
Answer:
C++ code is given below
Explanation:
#include<iostream>
#include <cstring>
using namespace std;
int housekeeping(string EOFNAME);
int mainLoop(string name,string EOFNAME);
int finish();
void main()
{
string name;
string EOFNAME = "ZZZZ";
cout << "enter the name" << endl;
cin >> name;
if (name != EOFNAME)
{
housekeeping(EOFNAME);
}
if (name != EOFNAME)
{
mainLoop(name , EOFNAME);
}
if (name != EOFNAME)
{
finish();
}
system("pause");
}
int housekeeping(string EOFNAME)
{
cout << "enter first name " << EOFNAME << " to quit " << endl;
return 0;
}
int mainLoop(string name, string EOFNAME)
{
int hours;
int rate,gross;
int DEDUCTION = 45;
int net;
cout << "enter hours worked for " << name << endl;
cin >> hours;
cout << "enter hourly rate for " << name << endl;
cin >> rate;
gross = hours*rate;
net = gross - DEDUCTION;
if (net > 0)
{
cout << "net pay for " << name << " is " << net << endl;
}
else
{
cout << "dedections not covered.net is 0.";
}
cout << "enter next name or " << EOFNAME << " to quit" << endl;
cin >> name;
return 0;
}
int finish()
{
cout << "end of job"<<endl;
return 0;
}
Answer:
Form the given statement i have come to know that the by changing hidden form values attacker has been able to modify the purchase price.
Explanation:
User can change a hidden field is not different from a common field from browser or server side.
If you want to store data then user must have to store them on server -side on a session and it is a fastest way.
Answer:
Option C (DMCA) would be the correct choice.
Explanation:
- DMCA is designed to govern electronic channels and tackle the problems the online revolution confronts regarding copyright.
- DMCA's mission seems to be to accommodate the rights of intellectual property producers and investors and investigate anything other than a copyrighted material that really occurs throughout the digital environment.
The other given choice are not related to the given content. So that option C is the right one.