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. The 6 main categories of operators are: ____ - arithmetic - comparison - logical - bitwise and membership
cycles
assignment
-
value
2. 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
conform
polymorphism
static typing
struct
3. The part of an Objective-C class specification that defines public methods (those declared in the class's interface) as well as private methods (those not declared in the class's interface).
nil
cycles
implementation
framework
4. A tool that lets you graphically specify your application's user interface. It sets up the corresponding objects for you and makes it easy for you to establish connections between these objects and your own code where needed.
inheritance hierarchy
null
protocol
Interface Builder
5. An architecture that facilitates communication between objects in different address spaces.
event
value
class
distributed objects
6. Objective-C's protocols are really about communicating _____ _______
developer intent
+
AppKit
zero
7. 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.
@interface
class
class object
instance
8. _____ data types can be both positive and negative
protocol
asynchronous message
floating-point
Signed
9. A ____ ____ is a situation where you free memory and then accidentally continue to use it
factory
zero
dangling pointer
cannot
10. The most flexible C data type: ______
message expression
struct
Protocols
attributes
11. Square bracket syntax for calling a method
Cocoa
C operators
[receiver message];
encapsulation
12. A class that's one step above another class in the inheritance hierarchy; the class through which a subclass inherits methods and instance variables.
attributes
message expression
event
superclass
13. A protocol declared as a category usually as a category of the NSObject class.
informal protocol
copy
null
class
14. A memory-management technique in which each entity that claims ownership of an object increments the object's reference count and later decrements it; allows one instance of an object to be safely shared among several other objects.
ampersand (&)
reference counting
interface
-
15. The part of an Objective-C class specification that declares its public interface which includes its superclass name & instances variables and public-method prototypes.
ampersand (&)
interface
category
assign
16. 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.
category
structures
abstract class
object
17. In Objective-C floats are more commonly used than ______
doubles
inheritance
-
cycles
18. ARC is susceptible to retain _____
interface
distributed objects
nil
cycles
19. 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.
formal protocol
copy
fields
adopt
20. 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.
AppKit
memory leak
dereference (dereferencing)
properties
21. 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
Binary
NSString
Unsigned
Encapsulation
22. In the Objective-C language the declaration of a group of methods not associated with any particular class.
nil
protocol
nonatomic
Categories
23. In a format string the place holder for an object is ______
attributes
%@
value
properties
24. Xcode sequence to examine an app for memory leaks or retain cycles
Product>Profile>Leaks>Profile
init
assign
deprecated
25. 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
method
properties
mutex
synchronous message
26. Property attribute that synthesizes only a getter for the property
readonly
chars
%@
class
27. If you are compiling an application with ARC (Automatic reference Counting) you _______ store Objective-C objects inside a struct
superset
double
cannot
%
28. _____ allow you to add new methods to existing classes
Interface Builder
message
Categories
anonymous object
29. An advanced object-oriented development platform in Mac OS X; a set of frameworks whose primary programming interfaces are in Objective-C.
Cocoa
dispatch table
Categories
@implementation
30. ____ provide a concise & elegant method for defining a discrete set of values
id
weak
properties
Enumerations
31. Same as class object. (first way to say it.)
remote message
NSString
factory
pointer
32. C-style strings are stored in an array of _____
[receiver message];
link time
AppKit
chars
33. A prototype for a particular kind of object; declares instance variables and defines methods for all members of the class.
message expression
AppKit
dynamic binding
class
34. All objects are created on the _____
zero
assignment
heap
Protocols
35. An object that acts on behalf of another object.
inheritance
delegates
delegate
Smalltalk
36. Three main categories of more complicated data structures:_______ - arrays and structs
developer intent
pointers
asterisk (*)
structures
37. Symbol used to denote a placeholder in a format string
runtime
cannot
strong
%
38. The init... method that has primary responsibility for initializing new instances of a class. Each class defines or inherits its own. Through messages to self other init... methods in the same class directly or indirectly invoke it and then it - thro
designated initializer
class
9
link time
39. _____ 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'.
long long
asterisk (*)
nonatomic
Encapsulation
40. Short for mutual exclusion semaphore. An object used to synchronize thread execution.
cannot
mutex
anonymous object
outlet
41. The name of a method when it's used in a source-code message to an object or the unique identifier that replaces the name when the source code is compiled.
runtime
long long
nil
selector
42. In object-oriented programming the object that is sent a message.
interface
designated initializer
receiver
class object
43. Objective-C methods are called using ____ _____
square brackets
Categories
message
dynamic typing
44. 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.
heap
static typing
null
instance
45. 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.
Binary
remote message
encapsulation
adopt
46. A method that can operate on class objects rather than instances of the class.
class method
NSObject
%
precedence
47. When creating a class implementation file you begin with the _____ keyword and close with the @end keyword
instance
@implementation
factory
Product>Profile>Leaks>Profile
48. Each class should have a ______ initializer a single method responsible for performing all of the object's setup and initialization.
instance
framework
remote object
designated
49. Consider: [NSString alloc]. 'alloc' is an example of a(n) class method rather than a _______ method
framework
instance
@implementation
designated
50. A compiler feature that provides automated memory management
Categories
ARC
dangling pointer
@implementation