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. Procedures (like verbs) are processes that manipulate or transform data and in Objective-C these 3 elements are _____ - functions and methods
binary
runtime
C operators
9
2. Xcode sequence to convert non-ARC apps to ARC
cycles
abstract class
Edit>Refactor>Convert to Objective-C ARC
%
3. Protocols are adopted by adding a ____________ list of protocols inside angled brackets after the superclass declaration in a class's @interface block
binary
message
comma-separated
interface
4. In object-oriented programming the hierarchy of classes that's defined by the arrangement of superclasses and subclasses. Every class (except root classes such as NSObject) has a superclass and any class may have an unlimited number of subclasses.
Signed
value
Categories
inheritance hierarchy
5. Property attribute that causes the setter to store a zeroing weak reference to the assigned value
chars
weak
null
instance
6. A struct may contain multiple ____ consisting of different data types
comma-separated
Pointers
Protocols
fields
7. a+b; is an example of using a _____ operator
assign
binary
Encapsulation
procedures
8. Symbol used to denote a placeholder in a format string
runtime
polymorphism
%
class method
9. Same as class object. (second way to say it.)
factory object
cannot
static typing
adopt
10. A ____ ____ is a situation where you free memory and then accidentally continue to use it
binary
weak
subclass
dangling pointer
11. Data types are divided into two main categories: integer and ______
synchronous message
floating-point
-
remote message
12. If you are compiling an application with ARC (Automatic reference Counting) you _______ store Objective-C objects inside a struct
floating-point
@implementation
cannot
NSObject
13. Objective-C's protocols are really about communicating _____ _______
factory object
dangling pointer
developer intent
class method
14. A prototype for a particular kind of object; declares instance variables and defines methods for all members of the class.
class
dangling pointer
init
adopt
15. All objects are created on the _____
heap
properties
implementation
nil
16. 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.
instance
pointers
attributes
heap
17. A programming technique that hides the implementation of an operation from its users behind an abstract interface; allows the implementation to be updated or changed without impacting the users of the interface.
encapsulation
assignment
struct
superset
18. 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).
printf( )
procedures
dynamic allocation
message expression
19. Zeroing weak referencing should be used for _____ and data sources to prevent inadvertent retain cycles
Binary
class
adopt
delegates
20. Objective-C borrows much of its syntax from ______ one of the earliest object-oriented languages
synchronous message
framework
Smalltalk
Cocoa
21. A logical subdivision of a program within which all names must be unique. Symbols in one do not conflict with identically named symbols in another.
namespace
ARC
selector
asterisk (*)
22. A remote message that doesn't return until the receiving application finishes responding to the message. Because the application that sends the message waits for an acknowledgment or return information from the receiving application - the two applica
dereference (dereferencing)
inheritance hierarchy
synchronous message
double
23. An object in another application - one that's a potential receiver for a remote message.
remote object
instance method
superclass
factory
24. Objective-C objects should use strong or weak ______
attributes
deprecated
formal protocol
encapsulation
25. The Objective-C runtime table that contains entries that associate method selectors with the class-specific addresses of the methods they identify.
instance
dispatch table
static typing
double
26. Consider: [NSString alloc]. 'alloc' is an example of a(n) class method rather than a _______ method
Categories
instance
dispatch table
zero
27. The 6 main categories of operators are: ____ - arithmetic - comparison - logical - bitwise and membership
receiver
zero
dereference (dereferencing)
assignment
28. An architecture that facilitates communication between objects in different address spaces.
init
square brackets
distributed objects
chars
29. A programming unit that groups together a data structure (instance variables) and the operations (methods) that can use or affect that data; the principal building blocks of object-oriented programs.
object
ARC
Encapsulation
Edit>Refactor>Convert to Objective-C ARC
30. A compiler feature that provides automated memory management
asterisk (*)
ARC
chars
class
31. Rather than using arrays in Objective-C we often are able to use it's collection classes of NSArray - NSSet and NSDictionary with _____ for strings
ampersand (&)
readwrite
NSString
procedures
32. 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.
Binary
distributed objects
outlet
[receiver message];
33. 3 Common Float data types: float - _____ - CGFloat
Interface Builder
precedence
Cocoa
double
34. Two additional foundational building blocks of Objective-C distinct from data and procedure type foundations: ________ and Categories/Extensions
unitary
printf( )
Protocols
designated
35. Property attribute that synthesizes only a getter for the property
dereference (dereferencing)
dynamic binding
readonly
heap
36. To destroy an object set the variable that points to it to _____
designated initializer
selector
nil
assign
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.
Cocoa
dispatch table
class object
assignment
38. Giving the compiler information about what kind of object an instance is - by typing it as a pointer to a class.
zero
weak
Signed
static typing
39. a++; is an example of using a _____ operator
static typing
precedence
remote message
unitary
40. There are ____ fundamental building blocks in Objective-C
%
Smalltalk
structures
9
41. In a home building analogy a ____ is the blueprint and the object is the house
nil
class
Enumerations
strong
42. 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
chars
object
conform
Product>Profile>Leaks>Profile
43. A variable that points to the memory address of another value
pointer
delegate
nil
Pointers
44. _____ 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'.
Encapsulation
pointers
memory leak
Unitary
45. When creating a class implementation file you begin with the _____ keyword and close with the @end keyword
runtime
instance method
structures
@implementation
46. Instance variables are optional in iOS if ________ are used
precedence
floating-point
designated
properties
47. In object-oriented programming - the method selector (name) and accompanying parameters that tell the receiving object in a message expression what to do.
C operators
message
binary
Enumerations
48. A Cocoa framework that implements an application's user interface; provides a basic program structure for applications that draw on the screen and respond to events.
comma-separated
AppKit
init
instance
49. In object-oriented programming the ability of a superclass to pass its characteristics (methods and instance variables) on to its subclasses.
Unitary
C operators
inheritance
static typing
50. 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.
dynamic binding
readonly
dynamic allocation
formal protocol