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

1. Write a program using Function Concept to Calculate Perimeter of Circle, Square, Triangle and Rectangle.

i. Function calPerimeterCircle that do not accept arguments and do not return value.

ii. Function calPerimeterSquare that do not accept arguments and return value.

iii. Function calPerimeterTriangle that accept arguments and do not return value.

iv. Function calPerimeterRectangle that accept arguments and return value

2. Please refer the following formula as guidance :

a. Perimeter of Circle = 2 π r : r = radius , use π= 22/7

b. Perimeter of Square = 4a : a = side

c. Perimeter of Triangle = a+b+c : a=side1, b=side2 and c= side3

d. Perimeter of Rectangle = 2 +(l+w) : l=length, w= width 


Consider the following program segment:

public class Ch7_PrExercise4

{

public static void main(String[] args)

{

int num;

double dec;

.

.

.

}

public static int one(int x, int y)

{

.

.

.

}

public static double two(int x, double a)

{

int first;

double z;

.

.

.

}

}


a. Write the definition of method one so that it returns the sum of

x and y if x is greater than y; otherwise, it should return x minus 2

times y.

b. Write the definition of method two as follows:

i. Read a number and store it in z.

ii. Update the value of z by adding the value of a to its previous value.

iii. Assign the variable first the value returned by method one with

the parameters 6 and 8.

iv. Update the value of first by adding the value of x to its previous

value.

v. If the value of z is more than twice the value of first, return z;

otherwise, return 2 times first minus z.

c. Write a Java program that tests parts a and b. (Declare additional variables

in the method main, if necessary.)


Encode, compile and run the following programs and do the following:

1. Identify the format of the function used: no return type & no parameter, with return type & no parameter, no return type & with parameter and with return type & with parameter.

2. Identify the format and actual parameters.

3. Identify the function signature

4. Identify parameter if value parameter, reference parameter or constant reference parameter is used.

5. Identify the the scope of variable used.

6. Identify the type of C++ function is used.

*Note see picture: https://drive.google.com/file/d/1BMDWtJ-Rn32VD8JYDIXCIK2I73AL3zOQ/view?usp=sharing


code (1) "Ch6_Largest.cp" "download the code"

https//drive.google.com/file/d/1s_57xZgbzTUs2MExfziY36jkMPp7svYq/view?usp=sharing


use this for example: https://drive.google.com/file/d/18Qsl8Kc1yn6VU-jLIqgFgJgRxJdjqMQc/view?usp=sharing


download them first.


1.   All the banks operating in India are controlled by RBI. RBI has set a well defined guideline (e.g. minimum interest rate, minimum balance allowed, maximum withdrawal limit etc) which all banks must follow. For example, suppose RBI has set minimum interest rate applicable to a saving bank account to be 4% annually; however, banks are free to use 4% interest rate or to set any rates above it.

 

 

Write a java program to implement bank functionality in the above scenario. Note: Create few classes namely Customer, Account, RBI (Base Class) and few derived classes (SBI, ICICI, PNB etc). Assume and implement required member variables and functions in each class.


Dieting is common in our society and everyone wants a piece of the action. So many diets are available to choose from if someone wants to change their health; e.g., lose weight. Often times, diets are promoted with claims of great success.

For the purposes of this assignment, you are to choose a particular diet and analyze it in terms of scientific evidence, or lack thereof. Then, you are to design a controlled experiment to test a hypothesis based on this diet. The experiment must include multiple individuals within a control and experimental group. You must specify how you will measure the outcome of the experiment identifying both the independent and dependent variables. You must describe the potential outcomes of the experiment in terms of supporting the hypothesis.

Write a 2-3 page (500 – 750 words, 12 point font) paper including the following elements. Be sure to compose your work with your own words. Do not copy and paste from any source.


In your assigned readings, you learned how inductive and deductive reasoning are used to answer questions about life. Briefly compare and contrast each type of reasoning as they apply to biological investigation. Which, if any, type of reasoning is best used to establish cause and effect relationships? Explain your rationale using one or more examples.



  • Create a C++ program using Fibonacci sequence is a numerical sequence such that after the second element all numbers are equal to the sum of the previous two elements.


1, 1, 2, 3, 5, 8, 13, 21, 34, 55, 89, ...


Write a program to calculate and print the first 20 elements of this sequence.  Use a 20-element array to perform this task


Write the code using C++,


(i) Write a function using C++ statements called PrintReport() which takes three float arrays (valuel, value2, value3) and an integer (as the size of the array) as parameters. The method prints the report as given below.

Day Machine A Machine B Machine C Minimum Maximum Total Average

1 15.5 50 35.5 A B 101 33.66

2 25.5 45.5 65 A C 136 45.33

3 27.5 25.5 71 B C 124 41.33

4 60.5 18 74.5 B C 153 51

Note: Should use functions already defined to find mimmum, maximum, total and average.

(j)   Implement the main method of a C++ program to do the followings:

1. Create 3 float arrays with the names machine A, machine B and machine C. The arrays are of size 4.

2.Insert machine A, B and C production to the respective array using the function InputProduction().

3. Print chart of all four (4) days by using the function PrintChart().

4.Print the report using the function PrintReport().


Write a bash script to check whether the input number is EVEN, ODD or neither EVEN nor


Suppose that you have a mobile phone. Initially the phone has a net value of 35000/-, it has

been used for 0 Hrs and its battery can last for 12 Hrs. Now after every month the phone is

used for 200 hrs on average and its battery backup time decreases by 4%. After every 4%

decrease in battery backup time, the price decreases by 700/-. You need to write a program by

using the concept of operator overloading to calculate the minimum number of months in

which the battery backup time will become less than or equal to 5 hrs and display the net

value and total hours of use and battery backup time of the mobile phone after those months.


LATEST TUTORIALS
APPROVED BY CLIENTS