User Tools

Site Tools


haas:spring2015:cprog:projects:cbf0

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
haas:spring2015:cprog:projects:cbf0 [2015/03/22 15:15] – [Submission] wedgehaas:spring2015:cprog:projects:cbf0 [2015/03/22 15:15] (current) – [Program] wedge
Line 56: Line 56:
 If you are successful, the image should render itself in the browser, and you should be able to recognize it (vs. it being unreadable and unrecognizable). The image is intended to be meme-like in original, and hopefully will invoke a mild sense of humor (that of course is optional). If you are successful, the image should render itself in the browser, and you should be able to recognize it (vs. it being unreadable and unrecognizable). The image is intended to be meme-like in original, and hopefully will invoke a mild sense of humor (that of course is optional).
  
-=====Program===== 
-It is your task to write a program that obtains a long integer value from the user, and processes that single value into separate array elements (one digit per array element). Determining the number of digits, you are to perform this "all from nine, last from ten" subtraction method on the number using array transactions, displaying a visual representation of the problem being solved to STDOUT. 
- 
-Your program should: 
-  * obtain its input from STDIN. 
-    * input should be in the form of a single (long) long integer value (you want a 64-bit data type) 
-  * determine the number of digits of the inputted value (store this in a variable) 
-  * process that input long integer into separate array elements- one digit per element. 
-    * you may assume a maximum array size of the maximum number of digits you're theoretically able to input that can be stored in a 64-bit value. 
-  * perform the "all from nine, the last from ten" operation on the array, storing the result in another array. 
-  * display the problem being solved, along with the answer 
-  * use functions to modularize your code: 
-    * have an **longint2array()** function that takes the long int, and returns an array (the function itself handles the processing of splitting up the long int into individual digits). 
-    * have a **printarray()** function, whose responsibility it is to display the indicated array to STDOUT. 
-    * have a **allfromnine()** function that takes the source array, does the processing, and returns ther result array. 
  
 =====Submission===== =====Submission=====
haas/spring2015/cprog/projects/cbf0.1427037318.txt.gz · Last modified: 2015/03/22 15:15 by wedge