100% satisfaction guarantee Immediately available after payment Both online and in PDF No strings attached 4.2 TrustPilot
logo-home
Exam (elaborations)

Object nOrientednProgrammingnMidterm nquestions nandncorrect nanswers

Rating
-
Sold
-
Pages
30
Grade
A+
Uploaded on
11-04-2025
Written in
2024/2025

Object nOrientednProgrammingnMidterm nquestions nandncorrect nanswers Object nOrientednProgrammingnMidterm nquestions nandncorrect nanswers Object nOrientednProgrammingnMidterm nquestions nandncorrect nanswers Object nOrientednProgrammingnMidterm nquestions nandncorrect nanswers Object nOrientednProgrammingnMidterm nquestions nandncorrect nanswers

Show more Read less
Institution
Object NOrientednProgramming
Course
Object nOrientednProgramming










Whoops! We can’t load your doc right now. Try again or contact support.

Written for

Institution
Object nOrientednProgramming
Course
Object nOrientednProgramming

Document information

Uploaded on
April 11, 2025
Number of pages
30
Written in
2024/2025
Type
Exam (elaborations)
Contains
Questions & answers

Subjects

Content preview

Object Oriented Programming Midterm
n n n




questions and correct answers
n n n n




Dividing na nprogram ninto nfunctions:
-is nthe nkey nto nobject-oriented nprogramming.
-makes nthe nprogram neasier nto nconceptualize.
n-may nreduce nthe nsize nof nthe nprogram.

-makes nthe nprogram nrun nfaster. n- nCORRECT nANSWERS--makes nthe
nprogram neasier nto nconceptualize.*

n-may nreduce nthe nsize nof nthe nprogram.




A nfunction nname nmust nbe nfollowed nby n______
{ nand n}
n[ nand n]

( nand n)
< nand n> n- nCORRECT nANSWERS-correct n( nand n)

A nfunction nbody nis ndelimited nby n______
{ nand n}
[ nand n]
( nand n)
< nand n> n- nCORRECT nANSWERS-{ nand n}

A nC++ ninstruction nthat ntells nthe ncomputer nto ndo nsomething nis ncalled na(n)
n_____

expression
statement
declaration
command n- nCORRECT nANSWERS-statement

An nexpression

- nusually nevaluates nto na n
numerical nvalue.
-indicates nthe nemotional nstate nof nthe nprogram.
-always noccurs noutside na nfunction.
-may nbe npart nof na nstatement. n- nCORRECT nANSWERS-*usually nevaluates nto
na nnumerical nvalue.




or

*correct nmay nbe npart nof na nstatement.

A nvariable nof ntype nchar ncan nhold nthe nvalue n301.

,true
false n- nCORRECT nANSWERS-false

What nkind nof nprogram nelement nis n12 n

-integer nconstant
-character nconstant
-floating-point nconstant
-variable nname nor nidentifier
-function nname
-malformed nor notherwise nincorrect ncode n- nCORRECT nANSWERS-integer
nconstant




What nkind nof nprogram nelement nis n'a' n

-integer nconstant
-character nconstant
-floating-point nconstant
-variable nname nor nidentifier
-function nname
-malformed nor notherwise nincorrect ncode n- nCORRECT nANSWERS-character
nconstant




What nkind nof nprogram nelement nis n4.28915

-integer nconstant
-character nconstant
-floating-point nconstant
-variable nname nor nidentifier
-function nname
-malformed nor notherwise nincorrect ncode n- nCORRECT nANSWERS-floating-
point nconstant

What nkind nof nprogram nelement nis nJungleJim?

-constant
-character nconstant
-floating-point nconstant
-variable nname nor nidentifier
-function nname
-malformed nor notherwise nincorrect ncode n- nCORRECT nANSWERS-variable
nname nor nidentifier




What nkind nof nprogram nelement nis nJungleJim()?

-integer nconstant
-character nconstant
-floating-point nconstant
-variable nname nor nidentifier
-function nname

, -malformed nor notherwise nincorrect ncode n- nCORRECT nANSWERS-function
nname




What nkind nof nprogram nelement nis n0xAF

-integer nconstant
-character nconstant
-floating-point nconstant
-variable nname nor nidentifier
-function nname
-malformed nor notherwise nincorrect ncode n- nCORRECT nANSWERS-integer
nconstant




Which nof nthe nfollowing nIS na nVALID nvariable nname?

-index n2
-index-2
-2index
-counter_2_index n- nCORRECT nANSWERS-counter_2_index

Choose nthe ncorrect ndescription nof nthe nfollowing ntwo nlines nof ncode.

n#include n<header1> n
n#include n"header2.h"




-Look nfor nheader1 nin nthe ncurrent ndirectory nand nheader2.h nwhere nsystem
nheader nfiles nare nstored

-Look nfor nheader1 nwhere nsystem nheader nfiles nare nstored nand nheader2.h nin
nthe ncurrent ndirectory

-header1 nis na nprogram-specific nheader nfile
-header2.h nis na nsystem nheader nfile n- nCORRECT nANSWERS-Look nfor
nheader1 nwhere nsystem nheader nfiles nare nstored nand nheader2.h nin nthe ncurrent

ndirectory




What ndoes nthe nfollowing ncode nprint?

int nx n= n10; n
int na n= nx++; n
cout n<< na n<< n" n" n<< nx n<< nendl;

11 n11
11 n10
10 n10
10 n11 n- nCORRECT nANSWERS-10 n11

What ndoes nthe nfollowing ncode nprint?

int nx n= n10; n
int na n= n--x; n
cout n<< na n<< n" n" n<< nx n<< nendl;
$7.19
Get access to the full document:

100% satisfaction guarantee
Immediately available after payment
Both online and in PDF
No strings attached

Get to know the seller
Seller avatar
ngugirouline078

Get to know the seller

Seller avatar
ngugirouline078 Teachme2-tutor
View profile
Follow You need to be logged in order to follow users or courses
Sold
0
Member since
8 months
Number of followers
0
Documents
3
Last sold
-

0.0

0 reviews

5
0
4
0
3
0
2
0
1
0

Recently viewed by you

Why students choose Stuvia

Created by fellow students, verified by reviews

Quality you can trust: written by students who passed their tests and reviewed by others who've used these notes.

Didn't get what you expected? Choose another document

No worries! You can instantly pick a different document that better fits what you're looking for.

Pay as you like, start learning right away

No subscription, no commitments. Pay the way you're used to via credit card and download your PDF document instantly.

Student with book image

“Bought, downloaded, and aced it. It really can be that simple.”

Alisha Student

Frequently asked questions