Question: code in Java Q1: Part 1: One can convert a number N to a base b using the following process: a. Divide N by b

code in Java Q1: Part 1: One can convert a number Ncode in Java

Q1: Part 1: One can convert a number N to a base b using the following process: a. Divide N by b b. Write down the quotient and remainder. c. Let the quotient be the new value of N and repeat the above until the quotient is zero. d. Write down the remainders in reverse order found -- this is the converted number As an example, to convert 1073 to base 5: 1073 = 214 * 5+ 3 214 = 42 * 5+ 4 42 = 8 * 5+2 8 = 1 * 5+ 3 1 = 0 * 5+1 Thus, 1073 written in base 5 is (13243), Which ADT among (Bag, Set, Stack, queue and List) is the most appropriate for this implementation and why? Part 2: Write a recursive method named Reverse LinkedList to reverse Linked List and what the time complexity for your method? Part 3: Write a method named Is BT Full to check whether the binary tree is full or not ?? Part 4: Which of the following algorithm pays the least attention to the ordering of the elements in the input list? a) Insertion sort b) Selection sort c) Quick sort d) None Given a number of elements in the range [O....n]. which of the following sorting algorithms can sort them in O(n) time? a) Counting sort b) Bucket sort c) Radix sort d) Quick sort For merging two sorted lists of size m and n into sorted list of size m+n, we require comparisons of a) O(m) b) O(n) c) O(m+n) d) O(logm + logn)

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Chemical Engineering Questions!