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
inn [45]
3 years ago
11

Where is the error in this code sequence?

Computers and Technology
1 answer:
Art [367]3 years ago
7 0

Answer:

There is an error in "String s=s1-s2 ";

Explanation:

In java programming, we can subtract subtract two strings variable with "-" operator.Java programming does not  support an overload of the '-' operator.In java, we can use only "+" operator to append two strings variable.There is no such method to subtract strings in java.Therefore in the given code String s=s1-s2 will give an "bad operand type" error because we can not subtract one string variable from the second string variable.

You might be interested in
Why should computers have a file structure?
UkoKoshka [18]
I am guessing "A" because you can store code anywhere and file structure does not prevent viruses.

hope this helped
 <span />
4 0
3 years ago
Read 2 more answers
What can you use to make sure that you have no errors in Word Online?
Free_Kalibri [48]

Answer:

You can use grammarly. It woks amazingly!

Explanation:

3 0
2 years ago
Lisa granted the CREATE TABLE privilege WITH ADMIN OPTION to Sharon. Sharon granted the privilege to Bob. If Lisa’s privileges a
GuDViN [60]

Answer:

D

Explanation:

As it's not fair if they all lose there privileges

4 0
3 years ago
A key step in the ____ approach to incident response is to discover the identify of the intruder while documenting his or her ac
muminat

Answer:d)apprehend and prosecute

Explanation: A intruder is a person who tries to access the system or damage it in an unauthorized manner. The person who is found with any intruding activity should be discovered.

Apprehending means of getting aware and prosecute defines the accusing of any person committing a crime .These activities define the nature of the intruder whose trying to commit the crime and should be detected while he  is pursuing the activity.Thus , the correct option is option(d).

7 0
3 years ago
Explain what the problems with the implementation of the function are, and show a way to fix them.// return true if two C string
Nataly [62]

Answer:

The code is not dereferencing the pointers. You have to place an asterisk in front of the pointer to read the value the pointer points to.

Explanation:

So "if (str1 != str2)" must be "if (*str1 != *str2)".

likewise:

   while (*str1 != 0 && *str2 != 0)

and

     result = (*str1 == *str2);

7 0
3 years ago
Other questions:
  • Which of the following is not an impact device?<br> Joy Stick<br> Track Ball<br> Mouse<br> Printer
    10·1 answer
  • What will happen if Sam goes to the View menu, clicks Toolbars, and then clicks Picture?
    12·2 answers
  • Which of the following is an advantage of using proprietary licensed software? The software’s source code can be easily modified
    7·2 answers
  • You are a network security administrator for a bank and you have noticed that an attacker has exploited a flaw in OpenSSL and fo
    9·1 answer
  • ) How many switching functions of two variables (x and y) are there?
    11·1 answer
  • Claudia has a bachelors degree in computer information systems and she has learned to use some popular software testing tolls wh
    13·2 answers
  • What is the best operating system
    12·1 answer
  • Which of the following is true about scalability?
    9·1 answer
  • Windows stores information from the Credential Manager application in secure folders called
    5·1 answer
  • It is a JavaScript property used to call a function after a specified time, in milliseconds​
    9·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!