1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
devlian [24]
3 years ago
9

Write a C# program named DoubleDecimalTest thatdeclares and displays two variables - a double and a decimal.Experiment by assign

ing the same constant value to each variable sothat the assignment to the double is legal but the assignment tothe decimal is not. In other words, when you leave the decimalassignment statement in the program, an error message should begenerated that indicates the value is outside the range of the typedecimal, but when you comment out the decimal assignment and itsoutput statement, the program should compile correctly.
Computers and Technology
1 answer:
il63 [147K]3 years ago
4 0

Answer:

whatt is this na ni??

Explanation:

You might be interested in
Why is a high-quality bond typically considered a lower-risk investment than a stock
FinnZ [79.3K]
Its high quality bond typically considered a lower risk investment than a stock because you need to find the answer on your own
5 0
2 years ago
Read 2 more answers
Hit and Slopes Program: A Write a program that can be used by a ski resort to keep track if local snow conditions for one week.
Llana [10]

Answer:

The java program is as follows.  

import java.lang.*;  

import java.util.Scanner;  

public class Main  

{  

//array declaration  

static int weekdays=7;  

static int[] snowfall_inch = new int[weekdays];  

static String[] snowfall_date = new String[weekdays];  

//variables to store average and maximum  

static double avg;  

static int max;  

public static void main(String[] args) {  

Scanner sc = new Scanner(System.in);  

System.out.print("Enter the month: ");  

String month = sc.next();  

for(int n=0; n<weekdays; n++)  

{  

System.out.print("\nEnter the date for day "+(n+1)+ ": ");  

snowfall_date[n] = sc.next();  

System.out.print("Enter the inches of snowfall for day "+(n+1) +": ");  

snowfall_inch[n] = sc.nextInt();  

avg = avg + snowfall_inch[n];  

}  

avg = avg/weekdays;  

System.out.printf("The average snowfall for the week is %.4f",avg);  

for(int n=0; n<weekdays-1; n++)  

{  

if(snowfall_inch[n] < snowfall_inch[n+1])  

max=snowfall_inch[n+1];  

}  

System.out.println("\nThe maximum snowfall for the week is "+max);  

}  

}  

OUTPUT  

Enter the date for day 2: 12-2-2019

Enter the inches of snowfall for day 2: 23  

Enter the date for day 3: 12-3-2019

Enter the inches of snowfall for day 3: 13  

Enter the date for day 4: 12-4-2019

Enter the inches of snowfall for day 4: 14  

Enter the date for day 5: 12-5-2019

Enter the inches of snowfall for day 5: 34  

Enter the date for day 6: 12-6-2019

Enter the inches of snowfall for day 6: 34  

Enter the date for day 7: 12-7-2019

Enter the inches of snowfall for day 7: 22

The average snowfall for the week is 21.7143  

The maximum snowfall for the week is 34  

Explanation:

1. Two arrays are declared to store dates and snowfall inches with string and integer datatypes respectively.  

2. Variables are declared to store maximum and average snowfall values with integer and double datatypes respectively.  

3. User input is taken for the month, and the dates and snowfall inch values for a week. The input is taken in for loop.  

4. Next, for loop is used to find the average and maximum snowfall of the week.  

5. These values are displayed to the user as shown in the output.

5 0
3 years ago
Write a function named times_ten. the function should accept an argument and display the product of its argument multiplied time
viva [34]
Since you did not specify a language  i am assuming C

void  x10(int   n){
printf("%d \n",n*10);
return;
}

3 0
3 years ago
Prove each statement using a proof by exhaustion. For every integer n such that 0 lessthanorequalto n &lt; 3, (n + 1)^2 &gt; n^3
yawa3891 [41]

Answer:

See attachment below

Explanation:

5 0
2 years ago
Shelby likes to play video games on an old Atari video game system. No matter how old the cartridge, when she inserts it into th
Nady [450]

Answer:

ROM (Acronym of Read-only memory. (video games))

Explanation:

7 0
3 years ago
Read 2 more answers
Other questions:
  • Whats the size of a short bond paper in microsoft word?
    10·1 answer
  • T F A stub is a dummy function that is called instead of the actual function it<br><br> represents.
    7·1 answer
  • #Write a function called hide_and_seek. The function should #have no parameters and return no value; instead, when #called, it s
    7·1 answer
  • Where do i put the lines?
    11·1 answer
  • Produce definition in computer
    9·2 answers
  • Create the logic for a program that prompts a user for 12 numbers and stores them in an array. Pass the array to a method that r
    8·1 answer
  • My feelings alwayss T-T
    14·2 answers
  • 3. Write a program to find the area of a triangle using functions. a. Write a function getData() for user to input the length an
    10·1 answer
  • What is the output of this program? Assume the user enters 2, 5, and 10.
    6·1 answer
  • Which bits of the address would be used in the tag, index and offset in a two-way set associative cache with 1-word blocks and a
    7·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!