Answer:
See the table attached for complete solution to the problem.
Answer:
The DoubleDecimalTest class is as follows:
using System;
class DoubleDecimalTest {
static void Main() {
double doubleNum = 173737388856632566321737373676D;
decimal decimalNum = 173737388856632566321737373676M;
Console.WriteLine(doubleNum);
Console.WriteLine(decimalNum); }}
Explanation:
Required
Program to test double and decimal variables in C#
This declares and initializes double variable doubleNum
double doubleNum = 173737388856632566321737373676D;
This declares and initializes double variable decimalNum (using the same value as doubleNum)
decimal decimalNum = 173737388856632566321737373676M;
This prints doubleNum
Console.WriteLine(doubleNum);
This prints decimalNum
Console.WriteLine(decimalNum);
Unless the decimal variable is commented out or the value is reduced to a reasonable range, the program will not compile without error.
Answer:
False
Explanation:
The revenue has to be considered when commercializing technology. Social, political and market support determine whether there will be customers or not. So when applying scenario logic to technology commercialization we have to consider if there is market for the technology, if the society is willing ot pay for the technology anf if politics of the region will allow the business to operate.
Answer:
C++.
Explanation:
#include <iostream>
using namespace std;
////////////////////////////////////////////////////////////////
void printPrime(int n) {
if (n > 0) {
cout<<2<<endl;
for (int i=3; i<=n; i++) {
bool isPrime = true;
for (int j=2; j<i; j++) {
if (i % j == 0) {
isPrime = false;
break;
}
}
if (isPrime == true)
cout<<i<<endl;
}
}
else {
cout<<"Invalid input";
}
}
int main() {
int n;
cout<<"Enter positive integer: ";
cin>>n;
printPrime(n);
return 0;
}
Answer:
an electronic device for storing and processing data, typically in binary form, according to instructions given to it in a variable program
Explanation:
Answer:
a divice to play games on, learn on, and other helpful things
Explanation:
Answer:
View Images.
Image1 = the code
Image2 = testcase 1
Image3 = testcase 2
Image4 = testcase 3
Answer:
// Application in java.
// package
import java.util.*;
// class definition
class Main
{
// method for calculating interest
public static float calculateInterest(float start_bal,float i_Rate)
{
// calculate return
float return_Amount=start_bal+(start_bal*(i_Rate/100));
// return
return return_Amount;
}
// main method of the class
public static void main (String[] args) throws java.lang.Exception
{
try{
// scanner Object to read the input
Scanner sc = new Scanner(System.in);
// variables
float start_bal;
float i_Rate=5;
// ask to enter start money
System.out.print("Enter start money:");
// read start money
start_bal=sc.nextFloat();
// call the function and print the return amount
System.out.println("5% interest earned on $" + start_bal + " after one year is $" + calculateInterest(start_bal,i_Rate));
}catch(Exception ex){
return;}
}
}
Explanation:
Declare and initialize interest rate with 5.Then read the start money from user.Then call the method calculateInterest() with parameter start_bal and i_Rate.It will calculate the return amount after 1 year.Print the returned amount in main method.
Output:
Enter start money:1500
5% interest earned on $1500.0 after one year is $1575.0