ECS 30 Study Guide - Midterm Guide: Binary File, Print Job

46 views2 pages

Document Summary

Hanly chapters 2-6: (10 points) you just printed something, and realize that it is a binary file that will print a bunch of garbage. Now you want to make sure that only you can read and write it. What unix command should you type: (5 points) you want to view the file test3. c a screen at a time. What unix command would you type: (25 points) given the following series of if statements, provide the outputs for each x. ___________________________________ c. ) w = x == y || x != y && z > x ___________________________________ d. ) w = !! (x * 4) + x % y. ___________________________________ (50 points) write a complete, warning-free, c program that lists all of the common factors of two positive integers. The program will prompt the user for the two numbers, and then list on one line all the factors that the numbers have in common.