Discover
Questions library
Collections library
Find online teacher
login
Discover
questions library
Find online teacher
login
Popular searches:
if-else
class-diagram
flowchart
Polymorphism
Home
Questions
Questions
Study lists
Asmaamasry Questions
705 Questions
Number of prime numbers) Programming Exercise 22.8 stores the prime numbers in a file named PrimeNumbers.dat
Java programming
2022-06-29
Answers
30
Question
40
Followers
30
0
0
143
(Geometry: gift-wrapping algorithm for finding a convex hull) Section 22.10.1 introduced the gift-wrapping algorithm for finding a convex hull for a set of points. Assume that the Java’s coordinate system is used for the points. Implement the algorithm using the following method:
Java programming
2022-06-29
Answers
30
Question
40
Followers
30
0
0
212
(All prime numbers up to 10,000,000,000) Write a program that finds all prime numbers up to 10,000,000,000. There are approximately 455,052,511 such prime numbers. Your program should meet the following requirements:
Java programming
2022-06-29
Answers
30
Question
40
Followers
30
0
0
218
(Closest pair of points) Section 22.8 introduced an algorithm for finding the closest pair of points using a divide-and-conquer approach. Implement the algorithm to meet the following requirements:
Java programming
2022-06-29
Answers
30
Question
40
Followers
30
0
0
165
(Execution time for GCD) Write a program that obtains the execution time for finding the GCD of every two consecutive Fibonacci numbers from the index 40 to index 45 using the algorithms in Listings 22.3 and 22.4. Your program should print a table like this:
Java programming
2022-06-29
Answers
30
Question
40
Followers
30
0
0
219
(Same-number subsequence) Write an O(n) program that prompts the user to enter a sequence of integers ending with 0 and finds the longest subsequence with the same number. Here is a sample run of the program:
Java programming
2022-06-29
Answers
30
Question
40
Followers
30
0
0
175
Pattern matching) Write a program that prompts the user to enter two strings and tests whether the second string is a substring of the first string. (Don’t use the indexOf method in the String class.) Analyze the time complexity of your algorithm. Here is a sample run of the program:
Java programming
2022-06-29
Answers
30
Question
40
Followers
30
0
1
260
(Pattern matching) Write a program that prompts the user to enter two strings and tests whether the second string is a substring of the first string
Java programming
2022-06-29
Answers
30
Question
40
Followers
30
0
1
140
(Maximum increasingly ordered subsequence) Write a program that prompts the user to enter a string and displays the maximum increasingly ordered subsequence of characters. Analyze the time complexity of your program. Here is a sample run:
Java programming
2022-06-29
Answers
30
Question
40
Followers
30
0
1
151
(Maximum consecutive increasingly ordered substring) Write a program that prompts the user to enter a string and displays the maximum consecutive increasingly ordered substring. Analyze the time complexity of your program. Here is a sample run
Java programming
2022-06-29
Answers
30
Question
40
Followers
30
0
1
175
(Addition quiz) Rewrite Programming Exercise 11.16 to store the answers in a set rather than a list
Java programming
2022-06-29
Answers
30
Question
40
Followers
30
0
1
131
(Web crawler) Rewrite Listing 12.18, WebCrawler.java, to improve the performance by using appropriate new data structures for listOfPendingURLs and listofTraversedURLs
Java programming
2022-06-29
Answers
30
Question
40
Followers
30
0
1
193
(Baby name popularity ranking) Revise Programming Exercise 21.11 to prompt the user to enter year, gender, and name and display the ranking for the name. Prompt the user to enter another inquiry or exit the program. Here is a sample run:
Java programming
2022-06-29
Answers
30
Question
40
Followers
30
0
1
162
Total:
705
Previous
39
40
41
42
43
Next
Go