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
Dmitriy789 [7]
3 years ago
8

Write an application named EnterUppercaseLetters that asks the user to type an uppercase letter from the keyboard. If the charac

ter entered is an uppercase letter, display OK; if it is not an uppercase letter, display an error message. The program continues until the user types an exclamation point. C# C# C#
Engineering
1 answer:
ozzi3 years ago
6 0

Answer:

The solution code is given below

  1. using System;
  2. using System.Linq;
  3.      
  4. public class Program
  5. {
  6. public static void Main()
  7. {
  8.  string[] letters = {"A", "B", "C", "D", "E", "F", "G", "H", "I", "J", "K", "L", "M", "N", "O", "P", "Q", "R", "S", "T","U", "V", "W", "X", "Y", "Z"};
  9.  
  10.  Console.WriteLine("Please input a letter: ");
  11.  string input_letter = Console.ReadLine();
  12.  
  13.  if(letters.Contains(input_letter)){
  14.   Console.WriteLine("OK");
  15.  }else{
  16.   Console.WriteLine("Error. Not uppercase letter.");
  17.  }  
  18. }
  19. }

Explanation:

Firstly we import the necessary libraries, System and Linq (Line 1-2).

Next we create a string array to hold all uppercase letters (Line 8).

Next, we prompt user to input a letter using the ReadLine() method (Line 10 - 11)

At last, we define if and else conditions to check if the letters contains the input letter. If so, print ok else print an error message. (Line 13-17)

You might be interested in
What was the reason alloys were used instead of metals like copper, tin, or iron?
lidiya [134]

Alloys were stronger and more durable

8 0
2 years ago
A commercial refrigerator with refrigerant -134a as the working fluid is used to keep the refrigerated space at -30C by rejectin
Mariana [72]

Answer:

a) 0.487

b) refrigeration load = 5.46w

c) cop = 2.24

d)ref load max = 12.43kw

Explanation:

6 0
3 years ago
Read 3 more answers
A series AC circuit contains a resistor, an inductor of 250 mH, a capacitor of 4.40 µF, and a source with ΔVmax = 240 V operatin
slega [8]

Answer:

Explanation:

Inductance = 250 mH = 250 / 1000 = 0.25 H

capacitance = 4.40 µF = 4.4 × 10⁻⁶ F ( µ = 10⁻⁶)

ΔVmax = 240, f frequency = 50Hz and I max = 110 mA = 110 /1000 = 0.11A

a) inductive reactance = 2πfl =  2 × 3.142 × 50 × 0.25 H =78.55 ohms

b) capacitive reactance = \frac{1}{2\pi fC} = 1 / ( 2 × 3.142× 50 × 4.4 × 10⁻⁶ ) = 723.34 ohms

c) impedance = \frac{Vmax}{Imax} = 240 / 0.11 = 2181.82 ohms

7 0
3 years ago
Read 2 more answers
Sort the following alphabets using MergeSort and give required steps. [2 Marks]
OlgaM077 [116]

Answer:

I'm afraid i can't visualise it to you but visit the site below to help you out <3

Explanation:

https://opendsa-server.cs.vt.edu/embed/mergesortAV

4 0
3 years ago
Which of the following answer options are your employer's responsibility?
tino4ka555 [31]

Answer:

Develop a written hazard communication program

Implement a hazard communication program

Maintain a written hazard communication program

Explanation:

To find - Which of the following answer options are your employer's responsibility?  Select all that apply.

Develop a written hazard communication program

Implement a hazard communication program

Maintain a written hazard communication program

Solution -

The correct options are -

Develop a written hazard communication program

Implement a hazard communication program

Maintain a written hazard communication program

All are the Responsibilities of an employer

Reason -

The most important duty of the employer is to stay alert and implement a correctly and efficiently written communication program related to hazards of the substances in the workplace.

He also has to maintain the program so that employees do not get affected.

3 0
3 years ago
Other questions:
  • A bar of 75 mm diameter is reduced to 73mm by a cutting tool while cutting orthogonally. If the mean length of the cut chip is 7
    10·1 answer
  • A mass of 0.3 kg is suspended from a spring of stiffness 0.4 N/mm. The damping is 3.286335345 kg/s. What is the undamped natural
    5·1 answer
  • A large part in a turbine-generator unit operates near room temperature and is made of ASTM A470-8 steel ( ). A surface crack ha
    11·1 answer
  • Pls help me answer my module
    13·1 answer
  • In your opinion, what is the external opportunity cost of a successful biking company in a community
    7·1 answer
  • Please help me in this assignment.
    13·1 answer
  • Often an attacker crafts e-mail attacks containing malware designed to take advantage of the curiosity or even greed of the reci
    14·1 answer
  • Turn the motor around in the circuit. What happens?
    12·1 answer
  • If an internally piloted DCV does not shift, you should use a gauge to _____. A.check the pilot line pressure b. check the inlet
    15·1 answer
  • It is possible to design a reactor where the scy conductor and the nitrogen/ammonia electrode operate at different temperatures.
    12·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!