A program that runs on ocelot for a mini calculator

Assignment Help Computer Engineering
Reference no: EM132196653

Question :

Write a C program that runs on ocelot for a mini calculator using only the command line options. You must use getopt to parse the command line.

Usage: minicalc [-a num] [-d num] [-m num] [-s num] [-e] value

• The variable value is the starting value.

• Value should be validated to be an integer between 1 and 99. Error message and usage shown if not.

• -a adds num to value.

• -d divides value by num.

• -m multiplies value by num.

• -s subtracts num from value.

• -e squares value. (Note: no num is needed.)

• Output should have exactly 2 decimal places no matter what the starting values are.

• If -e is included, it is executed first.

• Use standard order of operations for all operations.

Code should be nicely indented and commented. Create a simple Makefile to compile your program into an executable called minicalc.The Makefile should be called Makefile with no extension. I should be able to type make at the command line to compile your program.

Reference no: EM132196653

Questions Cloud

Test bench to perform row reduction on a matrix : Write a c program and test bench to perform row reduction on a 3 by 3 matrix and optimize to perform efficiently on the Zybo.
How do these assumptions influence the implications : How do these assumptions influence the implications and inferences you use in argument?
Simulate the operation of two of cpu scheduling methods : Write a C++ program to simulate the operation of two of CPU scheduling methods. Get the number of processes from the user.
Discusses any themes that relates to global business : Research and read objectively any academic article of your choice () that discusses any theme(s) that relate(s) to global business.
A program that runs on ocelot for a mini calculator : Write a C program that runs on ocelot for a mini calculator using only the command line options. You must use getopt to parse the command line.
Analysis divides on-hand inventory into three classes : The identification of parent items is called. ABC analysis divides on-hand inventory into three classes, generally based upon.
Develop a small application in flask : Develop a small application in Flask. The purpose of this application is to keep track of students that are enrolled in a class, and the score
Display the number of vowels in your name : Write a C program that stores your first name and your last name in separate arrays and counts and displays the number of vowels in your name.
Compare and contrast the two franchise agreements : Compare and contrast the two Franchise Agreements (Taste of Philly and Haagen Dazs) with respect to the contractual termination provisions.

Reviews

Write a Review

Computer Engineering Questions & Answers

  Test case creation

Test Case Creation, Using the following pseudocode, provide 3 unique test cases that would help validate your algorithm

  What are the benefits and risks of cloud computing

What are the benefits and risks of cloud computing for a business? Does a company you do business with use cloud computing? How so?

  Describe the steps you would use to test the plan

Describe the steps you would use to test the plan to ensure that the backup plan would function in case of an actual emergency.

  Define a 64-bit constant signed integer in flash

HCS12 : Define a 64-bit constant signed integer in Flash. Write a program that would divide it by 8 and stores the result in a 64-bit signed integer variable.

  Describe the superscalar architecture and vliw architecture

Describe in one paragraph the difference between the superscalar architecture and the VLIW architecture.

  Define physical plant operations

A fully configured computer facility, with all information resources and services, communication links, and physical plant operations

  Discusses four types of perceptual distortions

Discusses four types of perceptual distortions: stereotyping, halo effects, selective perception, and projection. Define each of these and provide an example.

  What are the common elements found in a project charter

Discuss what are the common elements found in a project charter. Also list the best practices of what should be conveyed to the project team during.

  Develop a scheme for solving the problem

Develop a scheme for solving the problem as an unconstrained minimization problem

  Discuss what are the key performance indicators

What are the Key Performance Indicators (KPIs) related to QoS

  Why to prepare a powerpoint presentaion

Are there any Websites that details the attributes of an effective PowerPoint presentation. Also what in your opinion would be one or two "best practices".

  Take a byte-addressable computer with 24-bit addresses

take a byte-addressable computer with 24-bit addresses, a cache capable of storing a total of 64KB of data, and blocks of 32 bytes. Show the format of a 24-bit memory address for.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd