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
In the figure show, what's the distance from point H to point C?
padilas [110]

Answer:

B.

Explanation:

I think not sure hehe

4 0
2 years ago
A fully charged new battery will have a low conductance reading.
Luda [366]

No it will have high conductance

8 0
2 years ago
Where can you find free air pods that look real
Tema [17]
You can find air pods that look real on letgo. or you can go to wish.com but if you want a good pair jus get the real ones
7 0
3 years ago
Nearlyof all serious occupational injuries and illnesses stem from overexertion of repetitive motion.
Ostrovityanka [42]

Answer:

a) 1/2

Explanation:

Overexertion accounted for more than  half of all events that resulted in a disabling condition.

Furthermore, 30% of all overexertion cases were reported in the services industry, on the other hand, 25% of injuries resulting from contact with objects and  equipment occurred in the manufacturing industry.

The above piece of information is taken from the bureau of labor statistics, Survey of Occupational Injuries and Illnesses

"LOST-WORKTIME INJURIES AND ILLNESSES: CHARACTERISTICS  AND RESULTING DAYS AWAY FROM WORK, 2002"

8 0
3 years ago
How is TEL (total equivalent length) measured and calculated? .​
ollegr [7]
Measure the longest circuit and add 50% for fittings and terminal units.
3 0
3 years ago
Other questions:
  • When a mesh in a circuit contains an independent or dependent current source, this leads to a special case of mesh-current analy
    14·1 answer
  • Not a characteristic property of ceramic material (a) high temperature stability (b) high mechanical strength (c) low elongation
    7·2 answers
  • Explain why the following acts lead to hazardous safety conditions when working with electrical equipmenta. Wearing metal ring o
    9·1 answer
  • Consider an InSb NW with ballistic mean free path of 150nm. Calculate the current through a 250nm long InSb NW when a 100mV bias
    6·1 answer
  • Air initially at 120 psia and 500o F is expanded by an adiabatic turbine to 15 psia and 200o F. Assuming air can be treated as a
    10·1 answer
  • For all the problems describe all pieces to the equations. 1.What is the equation for normal stress? 2.What is the equation for
    7·1 answer
  • If a particle moving in a circular path of radius 5 m has a velocity function v = 4t2 m/s, what is the magnitude of its total ac
    15·2 answers
  • What is the maximum volume flow rate, in m^3/hr, of water at 15.6°C a 10-cm diameter pipe can carry such that the flow will be l
    9·1 answer
  • BIG POINTS AND WILL GIVE BRAINLIEST! Answer all 5 please or I can’t give brainliest and might report!
    10·1 answer
  • A common boundary-crossing problem for engineers is when their home country' values come into sharp contrast with the host count
    7·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!