logo Hurry, Grab up to 30% discount on the entire course
Order Now logo

Ask This Question To Be Solved By Our ExpertsGet A+ Grade Solution Guaranteed

expert
Oscar BoltsGeneral article writing
(5/5)

921 Answers

Hire Me
expert
Motaz SData mining
(5/5)

688 Answers

Hire Me
expert
Nagendra Singh ChauhanMathematics
(/5)

909 Answers

Hire Me
expert
Riya ChopraComputer science
(5/5)

768 Answers

Hire Me
C Programming

Write a program using C language that will read in a set of numbers into an array.

INSTRUCTIONS TO CANDIDATES
ANSWER ALL QUESTIONS

Write a program using C language that will read in a set of numbers into an array. [ Through linux ]

  1. The command line arguments that your program should take are -h and -n (these argument should be handled using getopt).
  • If -his given then: Program should terminate with help message indicating how it should run. [ ex: "Usage message: ./file 1 2 3 3 2 1" ]
    • If -nis given then: Program will specify the minimum number that your script file can take in. For example, if the user enters " ./file -n 5 57 17 8 3 57 19 57 " then this would indicate that you were running your program with an argument of -n 5, and arguments of 57, 17, 8, 3, 19 and 57.
  1. Program should also only allow one duplicate--each number can only be read in max of 2 times.So no more than 2 quantities of the same number. Example, if " 3 3 32 10 1" is entered by user, then only "3 3 2 10 1" is read in.
  2. After these numbers are read into an array, pass this array to a functionthat will return the array in reverse. Ex: If the passed array is [11 56 3 22 3 1] then the returned array will be [1 3 22 3 56 11].
  3. Then, compare the new array to your old arrayand report (display) if it's the same backwards and forwards. Output both arrays element by element and display to user if it's the same in reverse.

Output example:

Old array: [1 2 3 3 2 1]
New Array: [ 1 2 3 3 2 1]
Result: Array is the same in reverse.

or

Old array: [ 1 3 4 5 10 ]
New Array: [ 10 5 4 3 2 1 ]
Output: Array is not the same in reverse.

** Implement this project using at least 3 source files: main.c , functions.c, functions.h . Must have a makefile that will compile the project

Related Questions

. The fundamental operations of create, read, update, and delete (CRUD) in either Python or Java

CS 340 Milestone One Guidelines and Rubric  Overview: For this assignment, you will implement the fundamental operations of create, read, update,

. Develop a program to emulate a purchase transaction at a retail store. This  program will have two classes, a LineItem class and a Transaction class

Retail Transaction Programming Project  Project Requirements:  Develop a program to emulate a purchase transaction at a retail store. This

. The following program contains five errors. Identify the errors and fix them

7COM1028   Secure Systems Programming   Referral Coursework: Secure

. Accepts the following from a user: Item Name Item Quantity Item Price Allows the user to create a file to store the sales receipt contents

Create a GUI program that:Accepts the following from a user:Item NameItem QuantityItem PriceAllows the user to create a file to store the sales receip

. The final project will encompass developing a web service using a software stack and implementing an industry-standard interface. Regardless of whether you choose to pursue application development goals as a pure developer or as a software engineer

CS 340 Final Project Guidelines and Rubric  Overview The final project will encompass developing a web service using a software stack and impleme