Create an array of type float with 10 elements. Write a modular program that does the following: Read values from keyboard input that represent salaries; store these in the array as they are entered. Once the array is full, give each one a 20% pay rise! Display the new salaries. Find the largest salary and display this, along with the index where it occurs.
Q: Create an array in C of type float with 10 elements. Write a modular program that does the…
A: Modular programming is all about breaking down the code in smaller parts. Every operation is…
Q: Create an array of type float with 10 elements. Write a modular program that does the following:…
A: note:- In your programming , there are many mistakes. The first is const size can’t be passed in…
Q: Implement one of the sorts described in Chapters 15 and 16. Input is an array with at least 10…
A: ALGORITHM:- 1. Take the input for the array of 10 elements which represent the number of visitors in…
Q: Write the following program in JAVA A magic square is an n x n matrix which, if filled with numbers,…
A: Ask the user for the size of the matrix and take the value of the matrix according to the size in…
Q: Consider an array of employee salary with the following values 1000.5, 250.3, 353.4, 424.5, 555.6,…
A: Hey there, I am writing the required solution based on the above given question. Please do find the…
Q: Write down declarations for variables of the following type (you get to choose the name): a) An…
A: Write down declarations for variables of the following type (you get to choose the name): a) An…
Q: Write a function that search an item in the array -ubmission (1) data array DWORD 1@h,20h, 30h, 40h,…
A: Answer: I have given answer in the handwritten format.
Q: Write a program in ¢++ that asks the user to enter 10 integers of an array . The program must return…
A: #include<iostream> using namespace std; int pos(int arr[]){ //return position of element…
Q: Write a function that partitions the array into two subarrays: one with all even integers, and the…
A: Python does not have built-in support for Arrays, but Python Lists can be used instead. In Python,…
Q: Write a code in C++ / cpp to solve the following problem Sasha has an array that contains each…
A: Increasing order 3 time pic the value in the array and for that code is below step.
Q: Write a C program that asks the user for 10 integer numbers and stores these numbers in an array.…
A: Algorithm: Start Set i=0 Set sum=0 Read A[i] Compute: sum +=A[i] Set i=i+1 IF i<10 go to step 4.…
Q: Write a function that returns an integer that appears most often with respect to an array of…
A: First of all. Student have not mention that in which languge this programe should be solved. So I…
Q: Create a array of size n and poulate it with random numbers. Print the array after populating. Take…
A: Write a C++ program to create a array of size n and poulate it with random numbers. Print the array…
Q: Write java program an application program that could be used to find the numbers divisible by 24…
A: Java has Random class in java.util package which can be used to generate random integers by calling…
Q: Write a program which takes 2 arrays of 10 integers each, a and b. c is an array with 10 integers.…
A: Here I have coded using C++ language. I have declared all the 3 arrays a,b, and c. Next, I have…
Q: Part1: Read an integer input from the user and save it to a variable 'size'. - Use the…
A: Required: Part1: Read an integer input from the user and save it to a variable 'size'. - Use…
Q: Write a java program which: a. Create an array of length 10 b. Populate the array using method.…
A: The java program is given by public class Main{ public static void main(String[] args) { int[]…
Q: Write a program that will calculate course and overall final mark (averages). You write a universal…
A: Step-1: StartStep-2: Declare two int variable courses and assignments and take input from…
Q: The java program ArrayTest.java is intended to do the following: · Fill the array a with integer…
A: We have to write a Java program Shift the elements of first element to the right one position and…
Q: Can you help me with this program? In Java! Define a two-dimensional array of names. For each…
A: PROGRAM: //Main.java public class Main { public static void main(String[] args) {…
Q: PLZ help with the following in Java try abd keep it simple so i can understand Missing sequential…
A: GIVEN: PLZ help with the following in Java try abd keep it simple so i can understand Missing…
Q: Read in two integers n and m (n, m < 50). Read n integers in an array A. Read m integers in an array…
A: Intersection finds all the common elements in A and B array. Union finds all the elements of A and B…
Q: The mechanics described in this exercise can be used to implement a game lights out. For basic…
A: // C++ Code For A Boolean Matrix Question#include <bits/stdc++.h> using namespace std;#define…
Q: Write Java program that named after your first name that will prompts the user (Scanner) to enter 5…
A: The program is implemented in Java using procedural approach. The function first accept five…
Q: Problem2 Write a program that display the position of a given element in an array. You should print…
A: Given:
Q: Create a array of size n and poulate it with random numbers in range @ to 15e. Print the minimum…
A: Write a C++ program. Create a array of size n and poulate it with random numbers in range 0 to…
Q: Define a function that will output an array of values of type double that is passed as an argument…
A: Note :- You have not mention the language of the program, so i'm answering your question in C++.…
Q: Problem D. 73511. Quarters Input file: Output file: standard input standard output 1 second 256…
A: #include <stdio.h> int main() { int m,n; //read m and n scanf("%d…
Q: An array my_Array[] consisting ‘a’ s, ‘b’ s and ‘c’s. The task is to write a function that arranges…
A: Approach: Here, we use bubble sort in a function to sort an array of characters. Two adjacent…
Q: Please write a java code using the JOptionPane class for input/output. Function read list_of_bids…
A:
Q: Read in an integer n (n < 25). Read n integers in an array A. Then do the following (write separate…
A: Python Python includes the function sum(), which sums the numbers in the list. Syntax: sum…
Q: Write a program which takes 2 arrays of 10 integers each, a and b. c is an array with 10 integers.…
A: Here I have coded using Java language. I have declared all the 3 arrays a,b, and c. Next, I have…
Q: Given an array A, push all the zeros of the array to the front. The order of all other elements…
A: import java.util.Arrays;class Main{public static void pushZero(int[] A){int current = A.length -…
Q: contains a Java program that prompts for and reads in the sales for each of 5 salespeople in a…
A: Task : Given the incomplete code. The task is to complete the code and find the output.
Q: Read in two integers n and m (n, m < 50). Read n integers in an array A. Read m integers in an array…
A: #include <stdio.h> int main(){ int a[50], b[50],m,n,i,j; int x,y,z; printf("Enter…
Q: Write a program that accepts an integer value called multiplier as user input. Create an array of…
A: function PrintForward(int array[],int ARRAY_SIZE)- Start for i = 0 to ARRAY_SIZE-1 print array[i]…
Q: Write a program to: fill array by 10 integers Find the second maximum Print the array Print the…
A: Please find the answer below :
Q: Write a program that will calculate course and overall final mark (averages). You write a universal…
A: Algorithm: Step-1: StartStep-2: Declare two int variable courses and assignments and take input…
Q: Write a java program with the following: Declare an array basic with 20 elements of type double.…
A: Here, we are storing the numbers in the array same as the array indices Or you can store any…
Q: Java Code 2. Search and Rescue by CodeChum Admin Make a program that will accept an integer and loop…
A: Program: //import packageimport java.io.*;import java.util.*;//Main classpublic class Main{…
Q: Write a program that take 10 values as input in an array, calculate its average, print that array…
A: THIS IS A MULTIPLE QUESTION BASED PROBLEM. ONLY FIRST PART IS SOLVED. KINDLY SEND THE REMAINING…
Q: Ask the user to enter an integer (n) Declare an array of size n with double data type. Ask the user…
A: Since no programming language is mentioned, I am using python. Algorithm: Start Read array size n…
Q: Read in an integer n (n < 25). Read n integers in an array A. Then do the following (write separate…
A: Code: #include<stdio.h>#include <stdlib.h> int main() { int n; printf("Enter n…
Q: Consider an array of student marks with the following values 5.5, 6.8, 7.2, 8.5, 9.5, 10.1, 11.2,…
A: Provided below is the single python program, in order to perform the given operations on array. Also…
Q: Write the following Java program Allocate an array a of ten integers. Put the number 17 as the…
A: To Allocate an array a of ten integers. int a[] = new int[10]; a[ ] is the array int [10] will…
Q: This must be done in Python, and include a 2 dimensional array to keep a record of the games played…
A: The complete code is given below.
Q: Write a modular program that analyzes a year’s worth of rainfall data. In addition to main, the…
A: Given: Write a modular program that analyzes a year’s worth of rainfall data. In addition to main,…
Q: Write a main program that does the following: Declares a one dimensional array A[ 6] of type int.…
A: Program Approach: Include the necessary header files for the standard I/O operations. Define a main…
Q: Write in Java. Given an array A, push all the zeros of the array to the front. The order of all…
A: Actually, array is a collection of elements.
Create an array of type float with 10 elements. Write a modular program that does the following:
-
Read values from keyboard input that represent salaries; store these in the array as they are entered.
-
Once the array is full, give each one a 20% pay rise!
-
Display the new salaries.
-
Find the largest salary and display this, along with the index
where it occurs.
Step by step
Solved in 3 steps with 1 images
- Create a LookupNames project. In the main function:Ask the user to enter a number of names, X to quit input.Store the names in an array.Also use a counter variable to count the number of names entered. Write a function displayNames to display the names.The function must receive the array and the counter as parameters. Write a function called lookupNames.The function must receive the array and the counter as parameters.Ask the user to enter a letter.Display all the names with the letter that was entered as the first letter of the name. Call the displayNames and lookupNames functions from the main function. Tip: declare your functions above the main() function: void displayNames(char array[][60], int count){ // function code here} int main(){ // main code here displayNames(names, number); // possible more code here} Tip2: make sure your function parameter matches the data type you send as an argument to that function.In the above example, names and array should have the same data…Java Program - Functions with 2D Arrays Write a function named displayElements that takes a two-dimensional array, the size of its rows and columns, then prints every element of a two-dimensional array. Separate every row by a new line and every column by a space. In the main function, write a program that asks for integer input to be assigned on a 3 x 3 array and call the function displayElements to print the contents on the next line. Input 1. Multiple lines containing integer each line Output R1C1: 1 R1C2: 2 R1C3: 3 R2C1: 4 R2C2: 5 R2C3: 6 R3C1: 7 R3C2: 8 R3C3: 9 1 2 3 4 5 6 7 8 9Create an array of type float with 10 elements. Write a modular program that does the following: Read values from keyboard input that represent salaries; store these in the array as they are entered. Once the array is full, give each one a 20% pay rise! Display the new salaries. Find the largest salary and display this, along with the index where it occurs. #include <iostream> #include <stdio.h> int input(); int pay_rise(); const int element= 10; int input(float elelment[]) { int n; for(n=0;n < element;n++); { printf("enter salaries %d",n); scanf("%d",&n); } return n; } int pay_rise(float element[]) { int n; for(n=0; n < element;n++); { element[n] * 1.1; } return n; } int display(float element) { } void largest number() { } int main() { float array[elements]; }
- Write a Java program to display a three_month delivery report for three different years. The following rows and columns represents the deliveries made for each year Jan Feb Mar DELIVERIES 2018 128 135 139 DELIVERIES 2019 155 129 175 DELIVERIES 2020 129 130 185 Use a Two-Dimensional array, produce the deliveries report, including the deliveries made statistics. The deliveries made statistic must display the total, maximum and minimum deliveries made in the two-dimensional array.2. A store owner wants the total sales for 2020. Write a program that will load an array with 12 months of sales. Use iomanip to make a nice-looking chart that shows the monthly sales, the month with the highest sales, lowest sales, and average for the year sales. January ……………. $50,000 February…………… $60,000 March ……………….$80,000 April ………………..$106,000 May …………………..$50,000 June ………………..$190,000 July ………………….$900,000 August …………… $102,000 September ………..$70,000 October …………..$700,000 November………… $90,000 December …………$90,000 Total Sales for the year 2020 was ………………….………$ The month with highest sales was ****** at ………..$ The month with lowest sales was ****** at ………...$ The average of sales for the year was ……………………$ C++1.Enter a positive integer value n (6 <= n < 30) and take n integers from the user as input and store them in array a. Then move the elements of this array one step to the left and make the first element of the array the last element of the array. Shift this array with a function. Display integer value n, the array elements in original order and the array elements in modified order (after shifting). For example, if the original order of the array a is like below : a: 33 45 67 89 12 7 After shifting one step to the left, you should get the following order of the array а: a: 45 67 89 12 7 33
- Write one program that does the following: Ask the user for ten (10) grades, and store the data in an array. Compute the average of all the grades. Print the original ten grades and the average. Declare an integer array with the name of “grades” of size 10 in the main function. Create a function called “getGrades” that prompts the User for the grades and puts them in an integer array. The function will receive an integer array and the size of the array. In the function prototype and the function header, call the array “gradeArray” and call the size of the array "size." iii. Create a For Loop that cycles through each cell of the array. At each cell prompt the User for a grade. Store the grade entered by the User into the array cell. From main, send this function the array called “grades” and the size of the array. Create a function called “computeAverage” that computes the average of an array…Make a program in JavaIn this simulation there are 7 countries competing { Mexico, Canada, China, Japan, Spain, Australia, Italy}2.There are three types of dents {Gold, Silver, Bronze}3.Use constant values for array dimensions4.Country names and medal types should be stored in an array.5.Randomly assign values between 1 and 10 that represent the number of medals of the corresponding type that the corresponding country has won.6.Show a table that represents the information of the medal table. Table must include country header names and medal type7.Show the total number of medals that each country obtained8.Show the name of the country that got the most medals, no matter the type of medal.9.Show the name of the country that obtained the most Gold medalsWrite a program to create an answer sheet to read the student’s answers for a ten (10) item exam. It should then display a message indicating the score and remarks whether the student passed or failed the exam. (A student must correctly answer 6 of the 10 questions to pass the exam.) Here are the correct answers (key to correction), which should be initialized and stored in an array: TRUE FALSE TRUE FALSE FALSE FALSE TRUE TRUE TRUE FALSE
- Write a c++ program for an atm machine. Use an array with maximum number of accounts to be 100. ATM machine performs the following function: 1. create account An account must have a unique id and 4 digit number pin. eg id = "yo" pin = "4444". if the given unique id is already taken ask the user to enter another unique id. also make sure the pin contains numbers only. 2. Login prompt the user to enter id and pin. incase any of the two is incorrect, print an error message saying incorrect pin or id. 3. withdraw withdraw money from the available balance in the account. make sure the user is logged in. 4. deposit deposit money in the account and update the balance. again make sure user is logged in. 5. pin code change. this allows the user to change their pin. ask for previous pin code and then ask to enter new pin code. 6. balance print the balance that is in the account. 7. logout. logout from the system.A positive integer greater than 1 is said to be prime if it has no divisors other than 1 and itself. Write a program that asks the user to input an integer greater than 1, then display all of the prime numbers that less than or equal to the number entered. The program should work as follows: • Once the user has entered a number, the program should display an array with all of the integers from 2 up through the value entered. • The program should then use a loop to step through the array. The loop should pass each element to a method that displays the element whether it is prime number. Your result should look like, for example: Enter an integer greater than 1: 9 2, 3, 4, 5, 6, 7, 8, 9 2 is prime 3 is prime 4 is not prime 5 is prime 6 is not prime 7 is prime 8 is not prime 9 is not prime Using java programmingComplete the following program ArrayMax.java. The function max() should return a new array containing the max value of each corresponding value in two arrays. Below is the code, with the section that needs to be completed. The output should look exactly like what is given below, also