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
zavuch27 [327]
2 years ago
6

Given the String variables name1 and name2, write a fragment of code that assigns the larger of the two to the variable first (a

ssume that all three are already declared and that name1 and name2 have been assigned values). (Note: "larger" here means alphabetically larger, not "longer". Thus, "mouse" is larger than "elephant" because "mouse" comes later in the dictionary than "elephant"!)
Computers and Technology
1 answer:
Neporo4naja [7]2 years ago
6 0

Answer:

if ( name1 > name2) {

    first = name1;

} else {

    first = name2;

}

Explanation:

First you need take a decision for that reason you need and if - else structure to decide if asign the variable name1 or the variable name2 to the result. Later you can use an > or < to compare two strings because it use the ASCII code to compare wich one is larger than another.

if ( name1 > name2) {

    first = name1;

} else {

    first = name2;

}

You might be interested in
What is the purpose of the Excel Function Reference?
Citrus2011 [14]

Answer:

To look up functions and their purposes

Explanation:

Edg

3 0
2 years ago
You can use a(n) ______________to store large amounts of customer data for a website.
BaLLatris [955]

You can use a(n) <u>database server; Databases, like MySQL</u><u> and PostgresSQL, are widely used to store data.</u>to store large amounts of customer data for a website.

<h3>What is the difference between POP3 and IMAP coursera?</h3>

POP3 can only download email to one local device. IMAP can only download email to one local device. POP3 is used for sending emails. IMAP can download emails onto multiple devices.

<h3>When would you use IMAP?</h3>

IMAP and POP are two methods to access email. IMAP is the recommended method when you need to check your emails from several different devices, such as a phone, laptop, and tablet.

To learn more about database server, refer

brainly.com/question/23752341

#SPJ4

5 0
1 year ago
Authenticating information can be something a user knows, like a password; something a user has, like a smart card; or something
xenn [34]

Answer:. True

Explanation:

yes it is true in my opinion

8 0
2 years ago
Why do people on Brainly verify answers that are wrong. I got 90% and 80% percent on my tests because of it
Bezzdna [24]
I feel that, you can’t trust it.
3 0
3 years ago
Read 2 more answers
Bill needs to make a presentation in which he has to represent data in the form of a pyramid. Which feature or menu option of a
andreyandreev [35.5K]

Answer:If you need to use arrows in a chart, which feature or menu option of a word processing program would you use?

A.  

Picture

B.  

Shapes

C.  

Clip Art

D.  

SmartArt

E.  

Charts

Explanation:

7 0
3 years ago
Other questions:
  • What type of rain happens when cold air meets warm air
    14·1 answer
  • What is a constructor? Why would you include a constructor in a class?
    6·1 answer
  • Think back over the information presented in the lesson about how you can skillfully use the Internet when doing research. Selec
    14·1 answer
  • Write a program that asks the user to enter a series of single digit numbers with nothing separating them. Read the input as a C
    12·1 answer
  • What are 3 similarities and 3 differences between live theatre and film/videos -Drama Class
    13·1 answer
  • Program a substitution cipher in Python. Create 2 functions one for encryption and the other for decryption ( get the text as th
    8·1 answer
  • Write a program in python to make the figure:-
    12·1 answer
  • Does watching Beastars make me a furry? ​
    12·1 answer
  • Why is it important to prepare the farm resources before you start working? explain​
    14·1 answer
  • Complete the sentence.
    12·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!