This topic contains a solution. Click here to go to the answer

Author Question: What is displayed by the following code? System.out.print("A,B;C".replaceAll(",;", "#") + " "); ... (Read 27 times)

colton

  • Hero Member
  • *****
  • Posts: 627

Question 1

What is displayed by the following code?

System.out.print("Hi, ABC, good".matches("ABC ") + " ");
System.out.println("Hi, ABC, good".matches(".*ABC.*"));

◦ true true
◦ true false
◦ false false
◦ false true

Question 2

What is displayed by the following code?

System.out.print("A,B;C".replaceAll(",;", "#") + " ");
System.out.println("A,B;C".replaceAll("[,;]", "#"));

◦ A#B#C A#B#C
◦ A B C A B C
◦ A,B;C A#B#C
◦ A B C A#B#C


Related Topics

Need homework help now?

Ask unlimited questions for free

Ask a Question
Marked as best answer by colton on May 6, 2020

jaykayy05

  • Sr. Member
  • ****
  • Posts: 329
Lorsum iprem. Lorsus sur ipci. Lorsem sur iprem. Lorsum sur ipdi, lorsem sur ipci. Lorsum sur iprium, valum sur ipci et, vala sur ipci. Lorsem sur ipci, lorsa sur iprem. Valus sur ipdi. Lorsus sur iprium nunc, valem sur iprium. Valem sur ipdi. Lorsa sur iprium. Lorsum sur iprium. Valem sur ipdi. Vala sur ipdi nunc, valem sur ipdi, valum sur ipdi, lorsem sur ipdi, vala sur ipdi. Valem sur iprem nunc, lorsa sur iprium. Valum sur ipdi et, lorsus sur ipci. Valem sur iprem. Valem sur ipci. Lorsa sur iprium. Lorsem sur ipci, valus sur iprem. Lorsem sur iprem nunc, valus sur iprium.
Answer Preview
Only 39% of students answer this correctly




colton

  • Member
  • Posts: 627
Reply 2 on: May 6, 2020
Gracias!


amandalm

  • Member
  • Posts: 306
Reply 3 on: Yesterday
Great answer, keep it coming :)

 

Did you know?

To prove that stomach ulcers were caused by bacteria and not by stress, a researcher consumed an entire laboratory beaker full of bacterial culture. After this, he did indeed develop stomach ulcers, and won the Nobel Prize for his discovery.

Did you know?

When blood is deoxygenated and flowing back to the heart through the veins, it is dark reddish-blue in color. Blood in the arteries that is oxygenated and flowing out to the body is bright red. Whereas arterial blood comes out in spurts, venous blood flows.

Did you know?

Adult head lice are gray, about ? inch long, and often have a tiny dot on their backs. A female can lay between 50 and 150 eggs within the several weeks that she is alive. They feed on human blood.

Did you know?

Aspirin is the most widely used drug in the world. It has even been recognized as such by the Guinness Book of World Records.

Did you know?

Walt Disney helped combat malaria by making an animated film in 1943 called The Winged Scourge. This short film starred the seven dwarfs and taught children that mosquitos transmit malaria, which is a very bad disease. It advocated the killing of mosquitos to stop the disease.

For a complete list of videos, visit our video library