SUBJECTS
|
BROWSE
|
CAREER CENTER
|
POPULAR
|
JOIN
|
LOGIN
Business Skills
|
Soft Skills
|
Basic Literacy
|
Certifications
About
|
Help
|
Privacy
|
Terms
|
Email
Search
Test your basic knowledge |
Objective C Programming Basics
Start Test
Study First
Subjects
:
it-skills
,
apple
Instructions:
Answer 50 questions in 15 minutes.
If you are not ready to take this test, you can
study here
.
Match each statement with the correct term.
Don't refresh. All questions and answers are randomly picked and ordered every time you load a test.
This is a study tool. The 3 wrong answers for each question are randomly chosen from answers to other questions. So, you might find at times the answers obvious, but you will see it re-enforces your understanding as you take the test each time.
1. Instance variables are optional in iOS if ________ are used
precedence
message expression
properties
Interface Builder
2. Placing a ____ before a normal variable name gives it's address
Categories
link time
ampersand (&)
%
3. A class is said to do this to a protocol if it (or a superclass) implements the methods declared in the protocol. An instance does this to a protocol if its class does. Thus an instance that does this to a protocol can perform any of the instance met
weak
conform
mutex
class
4. Objective-C methods are called using ____ _____
square brackets
procedures
chars
readwrite
5. A compiler feature that provides automated memory management
ampersand (&)
ARC
Cocoa
superclass
6. In object-oriented programming an expression that sends a message to an object. In the Objective-C language they are enclosed within square brackets and consist of a receiver followed by a message (method selector and parameters).
9
precedence
long long
message expression
7. The direct or indirect report of external activity especially user activity on the keyboard and mouse.
category
link time
event
long long
8. In object-oriented programming the ability of different objects to respond each in its own way - to the same message.
message expression
Signed
class object
polymorphism
9. If you are compiling an application with ARC (Automatic reference Counting) you _______ store Objective-C objects inside a struct
class method
pointers
readwrite
cannot
10. Objective-C objects should use strong or weak ______
attributes
unitary
adopt
inheritance hierarchy
11. There are ____ fundamental building blocks in Objective-C
9
structures
comma-separated
binary
12. Data (like nouns) represent the information we are processing and in Objective-C this made up of the four elements of C types - _____ - enums and objects
%
Enumerations
pointers
structures
13. The time after a program is launched and while it's running. Decisions made at during this time can be influenced by choices the user makes.
dynamic binding
runtime
factory
conform
14. Objective-C borrows much of its syntax from ______ one of the earliest object-oriented languages
Smalltalk
unitary
link time
attributes
15. _____ is one of the main advantages of object-oriented code and allows objects to 'hide away' much of their complexity operating at times like a proverbial 'black-box'.
printf( )
Encapsulation
class
struct
16. Procedures (like verbs) are processes that manipulate or transform data and in Objective-C these 3 elements are _____ - functions and methods
class
nonatomic
Edit>Refactor>Convert to Objective-C ARC
C operators
17. ______ data types are always zero or greate
dynamic allocation
Unsigned
copy
null
18. In computer science the mathematical concept of 'order of operations' is known as the 'order of ______'
selector
remote message
precedence
runtime
19. _____ operators take 2 operands
static typing
message expression
abstract class
Binary
20. Square bracket syntax for calling a method
class
[receiver message];
doubles
attributes
21. In the Objective-C language an object that belongs to (is a member of) a particular class; created at runtime according to the specification in the class definition.
Binary
printf( )
designated
instance
22. Property attribute that synthesizes only a getter for the property
Smalltalk
Edit>Refactor>Convert to Objective-C ARC
readonly
[receiver message];
23. A class that's one step above another class in the inheritance hierarchy; the class through which a subclass inherits methods and instance variables.
outlet
Binary
superclass
ampersand (&)
24. Objective-C's protocols are really about communicating _____ _______
Signed
developer intent
namespace
factory object
25. Property attribute that causes the setter to store a strong reference to the assigned value
class object
deprecated
strong
dispatch table
26. Short for mutual exclusion semaphore. An object used to synchronize thread execution.
event
pointer
runtime
mutex
27. In C all functions pass their arguments by ____ which means the compiler makes local copies of those arguments
unitary
dereference (dereferencing)
selector
value
28. A ____ _____ is where you forget to free up memory
memory leak
informal protocol
cycles
struct
29. In object-oriented programming a procedure that can be executed by an object.
cannot
method
readwrite
class method
30. A class that's defined solely so that other classes can inherit from it. Programs don't use instances of this; they use only instances of its subclasses.
selector
informal protocol
cannot
abstract class
31. ______ operators take a single operand
Unitary
Binary
assign
@implementation
32. The part of an Objective-C class specification that declares its public interface which includes its superclass name & instances variables and public-method prototypes.
interface
protocol
asynchronous message
init
33. Pointers are declared by placing a(n) ___ between the type declaration and the variable name
superset
C operators
asterisk (*)
link time
34. a++; is an example of using a _____ operator
remote message
unitary
binary
inheritance hierarchy
35. In Objective-C floats are more commonly used than ______
remote message
Enumerations
doubles
Pointers
36. Property attribute that causes the setter to store a copy of the assigned value
copy
floating-point
subclass
abstract class
37. Created by the compiler - lacks instance variables and can't be statically typed but otherwise behave like all other objects. As the receiver in a message expression - a it is represented by the class name.
inheritance
adopt
class object
Unitary
38. An instance variable that points to another object; _____ instance variables are a way for an object to keep track of the other objects to which it may need to send messages.
NSString
outlet
conform
designated initializer
39. A protocol that's declared with the @protocol directive. Classes can adopt these - objects can respond at runtime when asked if they conform to them and instances can be typed by those that they conform to.
instance
formal protocol
Unitary
implementation
40. _____ allow indirect access and modification of a variable's value.
Pointers
heap
Edit>Refactor>Convert to Objective-C ARC
readonly
41. This symbol denotes a method as being an instance method
memory leak
asynchronous message
-
cycles
42. To destroy an object set the variable that points to it to _____
class object
Categories
dangling pointer
nil
43. A remote message that returns immediately without waiting for the application that receives the message to respond. The sending application and the receiving application act independently and are therefore not in sync.
dispatch table
superset
asterisk (*)
asynchronous message
44. The process of setting or reading the value at an address pointed to by a pointer
%
init
object
dereference (dereferencing)
45. Finding the method implementation to invoke in response to the message
dynamic binding
mutex
Binary
[receiver message];
46. 7 Common Integer data types: BOOL - char- short - int - long - _____ - NSInteger
long long
delegate
designated
NSObject
47. In a home building analogy a ____ is the blueprint and the object is the house
runtime
instance
class
reference counting
48. Two additional foundational building blocks of Objective-C distinct from data and procedure type foundations: ________ and Categories/Extensions
fields
readwrite
unitary
Protocols
49. The 6 main categories of operators are: ____ - arithmetic - comparison - logical - bitwise and membership
Categories
assignment
dynamic binding
NSString
50. The time when files compiled from different source modules are linked into a single program. Decisions made by the linker are constrained by the compiled code and ultimately by the information contained in source code.
event
zero
remote message
link time