COSC1436 EXAM QUESTIONS WITH REVISED ANSWERS UPDATED
5 views 0 purchase
Course
COSC1436
Institution
COSC1436
COSC1436 EXAM QUESTIONS WITH REVISED ANSWERS UPDATED
Write the value in a, b, and c after each statement execution. The first two lines are done for you.
AFTER line 1 is executed, the value of x is 10, and y and z are undefined.
#include <iostream>
using namespace std;
int main()
{
...
COSC1436 EXAM QUESTIONS
WITH REVISED ANSWERS
UPDATED
Write the value in a, b, and c after each statement execution. The first two lines are
done for you.
AFTER line 1 is executed, the value of x is 10, and y and z are undefined.
#include <iostream>
using namespace std;
int main()
{
int x = 10; //line 1
int y = 20; //line 2
int z = 0; //line 3
z = x + y; //line 4
y = z % y; //line 5
x = y / z; //line 6 - Answer-line x y z
1 10 undef undef
2 10 20 undef
3 10 20 0
4 10 20 30
5 10 10 30
6 0 10 30
A sandbox is NOT to replace an IDE. T/F? - Answer-True
What software will we be using in class to create programs? - Answer-Visual Studios
What is the file extension of the source file (main file) created in an IDE? - Answer-.cpp
What does IDE stand for? - Answer-Integrated Development Environment
An IDE consists of text editor, compiler, debugger, and other utilities integrated into one
single component. T/F? - Answer-True
,bit
byte
variable
key word
operators - Answer-0 or 1
8 bits
Named storage location in a computers memory
reserved word in a program
+,-,/,*,=
A programmer writes source code and then the compiler/linker converts the source
code into machine instructions, or executable code. T/F? - Answer-True
Machine language code can be moved and run on any machine. T/F? - Answer-False
Programmer-Defined Identifiers are names made up by the programmer. T/F? -
Answer-True
Run-time error
compile-time error
source code
object code - Answer-logic errors
syntax-type error
the actual code the programmer writes
the code created by the compiler
Which of the following is NOT a programming language?
SynLang
Swift
BASIC
Python
, FORTRAN
Java
Ruby - Answer-SynLang
System software
Application software - Answer-Programs that manage the computer hardware and the
programs that run on them. (operating system)
Programs that provide services to the user. (word processor, games)
A(n) _________ are the instructions in a computer memory to make it do something.
operator
program
programmer
IDE - Answer-program
Each byte in memory is identified by a unique number known as an address. T/F? -
Answer-True
algorithm
main memory
secondary storage (disk drive)
cpu
portability
syntax - Answer-set of well-defined steps
when a program is running, it is stored here
when a program is not running, it is stored here
the part of computer that carries out the instructions
the ability of a language to let a programmer develop a program on a computer system
that can be run on other systems
the rules of grammar that must be followed when writing a program
True or False: The following code contains an error.
The benefits of buying summaries with Stuvia:
Guaranteed quality through customer reviews
Stuvia customers have reviewed more than 700,000 summaries. This how you know that you are buying the best documents.
Quick and easy check-out
You can quickly pay through credit card or Stuvia-credit for the summaries. There is no membership needed.
Focus on what matters
Your fellow students write the study notes themselves, which is why the documents are always reliable and up-to-date. This ensures you quickly get to the core!
Frequently asked questions
What do I get when I buy this document?
You get a PDF, available immediately after your purchase. The purchased document is accessible anytime, anywhere and indefinitely through your profile.
Satisfaction guarantee: how does it work?
Our satisfaction guarantee ensures that you always find a study document that suits you well. You fill out a form, and our customer service team takes care of the rest.
Who am I buying these notes from?
Stuvia is a marketplace, so you are not buying this document from us, but from seller Scholarsstudyguide. Stuvia facilitates payment to the seller.
Will I be stuck with a subscription?
No, you only buy these notes for $12.99. You're not tied to anything after your purchase.