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]
3 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]3 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
Technology __________ guides how frequently technical systems are updated, and how technical updates are approved and funded.
Nookie1986 [14]

Answer:

governance

Explanation:

5 0
2 years ago
Quick I need help ASAP
Alexeev081 [22]

Answer:

1. Spreadsheets are an essential business and accounting tool. They can vary in complexity and can be used for various reasons, but their primary purpose is to organize and categorize data into a logical format. Once this data is entered into the spreadsheet, you can use it to help organize and grow your business.

2. A spreadsheet is a tool that is used to store, manipulate and analyze data. Data in a spreadsheet is organized in a series of rows and columns and can be searched, sorted, calculated and used in a variety of charts and graphs.

3. ?


GOOD LUCK!

4 0
2 years ago
Read 2 more answers
An alteration threat violates information integrity. <br> a. True <br> b. False
Art [367]
The answer is True


It intentionally or unintentionally compromises a system by making unauthorized changes to data. As compared to intentional changes which are usually malicious, unintentional changes are normally accidental. Changes and modifications to the system configurations can also compromise integrity. Such modifications might include deleting, changing, and creating information in a network resource. It is best to implement mechanisms on how one can track and audit such changes as they happen




6 0
3 years ago
Which of the following demonstrates the proper way to specify a variable-length argument list?
larisa86 [58]

Answer:

The answer to this question is option "d".

Explanation:

In the given question option d is correct because variable-length argument is a new feature in J2SE 5.0 which stands for java 2 standard edition and 5.0 is the version name. It is the variable-length argument lists. A coder can create functions that uses a function to receive several parameter that is not specified. An argument type followed by an ellipsis(...) in the parameter list of a method means that a fixed number of arguments of that particular type is obtained by the method. and other options are not correct that can be given as:

  • In option a, we do not need to use the string the variable-length argument list. That's why it is wrong.
  • The option b and c are all wrong because in the last parameter the variable-length argument list is used.

That's why the answer to this question is the option "d".

7 0
3 years ago
To what would you compare the transport layer?
GarryVolchara [31]
The above question has multiple choices as below

<span>A. Data links
B. The post office
C. Driving a car
D. A train

The answer is (B) The Post Office.

In layman’s terms, transport layer is similar to the post office functions of delivering parcels and letters at the agreed delivery deadlines. It also notices any dropped info and re-transmits it.
Just like the post office, the transport layer directs messages and information between specific end users. If by mistake you write a letter to the wrong person, the letter will be returned and the postal employee will stamp it as address unknown.

</span>
4 0
3 years ago
Other questions:
  • What do you call the combination of title, description, tags, and thumbnail?
    6·1 answer
  • A file must be ________ before data can be written to or read from it. closed opened buffered initialized none of these
    11·2 answers
  • Write a program that accepts three decimal numbers as input and outputs their sums?​
    5·1 answer
  • Which different supports from a part of the matte box?
    8·1 answer
  • how to make assignment on power point plz cntct me and help me all about power point and my assignment is prime ministers of pak
    13·1 answer
  • WILL GIVE BRAINLIEST!!
    12·1 answer
  • In a Microsoft® Word® document, if a user wanted to organize information in rows in columns, they should select a
    5·1 answer
  • In the view that follows, which field can't be updated create view example_2 as select invoice_number, invoice_date, invoice_tot
    13·1 answer
  • The computer stores currently used programs and data in ________.
    9·2 answers
  • Once you select a theme, you__________ change the theme’s individual elements independently of each other.
    12·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!