Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Search & Filtering

What operation does the Selection Sort use to move numbers from the unsorted section to the sorted section of the list


Write a function to sort array elements using Selection sort in Descending order .also Compute the best case and worst case time complexity of selection sort.


The rectangular rule (also called the midpoint rule) is perhaps the simplest of the three methods for estimating an integral. i. Integrate over an interval a ≤ x ≤ b. ii. Divide this interval up into n equal subintervals of length h = (b − a)/n. iii.Approximate f in each subinterval by f(x*j ), where x*j is the midpoint of the subinterval. iv. Area of each rectangle: f(x*j)h, f(x*j)h,. . . , f(x*n)h. The approximation on the RHS becomes more accurate as more rectangles are used. In fact, You are required to: v. write pseudocode algorithm to determine the integral of a function between two specified points using the rectangular rule. vi. write C++ computer programs to determine the integral of a function between two specified points using the rectangular rule


Create a webpage that has an image that opens a page with the Wikipedia website when clicked. Refer to the sample below for clarification.

Note: When inserting the link to your image into your code, be sure to use the full URL, including https:// at the start of the URL.




Write java code to print following diamond patterns. This program must take number of lines from user. If even number is entered than program must ask again user to enter odd number.


Suppose that the input is:

58 23 46 75 98 150 12 176 145 -999

What is the output of the following program?

import java.util.*;

public class FindTheOutput

{

static Scanner console = new Scanner(System.in);

public static void main(String[] args)

{

int num;

num = console.nextInt();

while (num != -999)

{

System.out.print(num % 25 + " ");

num = console.nextInt();

}

System.out.println();

}

}


⦁ Write the algorithm for the convex hull problem using the divide and conquer technique and its time complexity.



Create a class called employee with the following details as variables within it.

1. Name of the employee

2. Age

3. Designation

4. Salary

Get the details of 5 employees and initialize it using Constructor. Release resources using destructor. print the name, designation and salary of employees, Find the highest salaried employee in professor grade and display their details.

(Initialize the class members using constructors and destroy the objects by using destructor)


Runtime Input :

Sri Ram 32 Prof. 70000

Skathi 31 Prof. 50000

Sanjay 29 AP 39050

Shiva 27 AP 37200

Guna 17 AP 25150


Output :

Employee Details:

Sri Ram Prof. 70000

Skathi ASP 50000

Sanjay AP 39050

Shiva AP 37200

Guna AP 25150


Highest Salaried Employee:

Sri Ram 32 Prof. 70000


Suppose you are given n sets:S1,S2.....Sn each set is having n elements.the problems is to find whether some pairs of these sets are disjoint,i.e. there are no common elements in these sets.write pseudo code and calculate its time complexity.


Correct the program so that it works properly.


import java.util.*;

public class Main {

static Scanner console = new Scanner(System.in);

public static void main(String[] args) {

char response;

double num1;

double num2;

System.out.println("This program adds two numbers.");

System.out.print("Would you like to run the program: (Y/y) ");

response = console.next().charAt(0);

System.out.println();

while (response == 'Y' && response == 'y')

{

System.out.print("Enter two numbers: ");

num1 = console.nextInt();

num2 = console.nextInt();

System.out.println();

System.out.printf("%.2f + %.2f = %.2f %n", num1, num2, (num1 - num2));

System.out.print("Would you like to add again: (Y/y) ");

response = console.next().charAt(0);

System.out.println();

}

}

}


LATEST TUTORIALS
APPROVED BY CLIENTS