Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

write 3 sepparate programs to do the following (java) in light of the policy please answere this one 1. (3 pts) (New string split method)

write 3 sepparate programs to do the following (java) image text in transcribed
in light of the policy please answere this one image text in transcribed
1. (3 pts) (New string split method) The split method in the String class returns an array of strings consisting of the substrings split by the delimiters. However, the delimiters are not returned. Implement the following new method that returns an array of strings consisting of the substrings split by the matching delimiters, including the matching delimiters. public static Stringsplit(Strings, String regex) a) split("ab#12#453","#") returns ab, #, 12, #, and 453 in an array of String. b) split("a?b?gf#e", "[?#]") returns a, ?, b, 7. gf, #, and e in an array of String. 2. (3pts) (Divisible by 5 or 6) Find the first 10 numbers greater than Long.MAX_VALUE that are divisible by 5 or 6 Bonus Question (3 pts): 3. (Square numbers) Find the first 10 square numbers that are greater than Long. MAX VALUE. A square number is a number in the form of n2. For example, 4, 9, and 16 are square numbers. Find an efficient approach to run your program fast. 1.(3 pts) (New string split method) The split method in the String class returns an array of strings consisting of the substrings split by the delimiters. However, the delimiters are not returned. Implement the following new method that returns an array of strings consisting of the substrings split by the matching delimiters, including the matching delimiters. public static Stringl split(String s, String regex) a) split("ab#12#453","#") returns ab, #, 12, #, and 453 in an array of String. b) split("a?b?gf#e", "[?#]") returns a, ?, b,?. gf, #, and e in an array of String

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database Design Application Development And Administration

Authors: Mannino Michael

5th Edition

0983332401, 978-0983332404

More Books

Students also viewed these Databases questions

Question

1. How do most insects respire ?

Answered: 1 week ago

Question

Who is known as the father of the indian constitution?

Answered: 1 week ago

Question

1.explain evaporation ?

Answered: 1 week ago

Question

Who was the first woman prime minister of india?

Answered: 1 week ago

Question

Explain the concept of going concern value in detail.

Answered: 1 week ago

Question

3. Is there opportunity to improve current circumstances? How so?

Answered: 1 week ago

Question

2. How will you handle the situation?

Answered: 1 week ago