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. Giving the compiler information about what kind of object an instance is - by typing it as a pointer to a class.
message
factory object
long long
static typing
2. Objective-C is a _____ of the C language
adopt
developer intent
superset
instance
3. Another name for a class that's defined solely so that other classes can inherit from it.
interface
heap
abstract superclass
pointer
4. The time when source code is compiled; constrained by the amount and kind of information encoded in source files.
instance
compile time
method
runtime
5. A ____ ____ is a situation where you free memory and then accidentally continue to use it
dangling pointer
doubles
nil
structures
6. _____ allow indirect access and modification of a variable's value.
class object
dangling pointer
Pointers
ARC
7. 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.
formal protocol
instance
value
namespace
8. _____ data types can be both positive and negative
dynamic allocation
mutex
Signed
subclass
9. 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.
link time
instance variable
Cocoa
event
10. In Objective-C floats are more commonly used than ______
Unsigned
doubles
distributed objects
receiver
11. Property attribute that causes the setter to store a zeroing weak reference to the assigned value
heap
weak
deprecated
%
12. If you are compiling an application with ARC (Automatic reference Counting) you _______ store Objective-C objects inside a struct
heap
delegate
cannot
synchronous message
13. Each class should have a ______ initializer a single method responsible for performing all of the object's setup and initialization.
outlet
Encapsulation
protocol
designated
14. Procedures (like verbs) are processes that manipulate or transform data and in Objective-C these 3 elements are _____ - functions and methods
readwrite
deprecated
C operators
9
15. Data types are divided into two main categories: integer and ______
delegate
floating-point
protocol
instance variable
16. A variable that points to the memory address of another value
copy
designated initializer
Pointers
pointer
17. In the Objective-C language the declaration of a group of methods not associated with any particular class.
protocol
Unsigned
null
deprecated
18. A compiler feature that provides automated memory management
object
dynamic allocation
ARC
+
19. _____ allow you to add new methods to existing classes
assignment
heap
anonymous object
Categories
20. 3 Common Float data types: float - _____ - CGFloat
double
Binary
+
class method
21. A class that's one step above another class in the inheritance hierarchy; the class through which a subclass inherits methods and instance variables.
pointer
@interface
selector
superclass
22. When creating a class header file you begin with the _____ keyword and close with the @end keyword
value
dynamic allocation
message
@interface
23. The root class in Objective-C
Binary
NSObject
%@
ampersand (&)
24. All objects are created on the _____
Binary
nil
instance variable
heap
25. 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.
NSObject
comma-separated
object
Unsigned
26. C-style strings always end with a ____ character
dynamic typing
structures
null
long long
27. Discovering the class of an object at runtime rather than at compile time.
fields
[receiver message];
dynamic typing
runtime
28. Protocols are adopted by adding a ____________ list of protocols inside angled brackets after the superclass declaration in a class's @interface block
designated
printf( )
comma-separated
nil
29. Objective-C methods are called using ____ _____
nil
long long
outlet
square brackets
30. The Objective-C runtime table that contains entries that associate method selectors with the class-specific addresses of the methods they identify.
struct
Enumerations
dispatch table
@implementation
31. In object-oriented programming a procedure that can be executed by an object.
@implementation
Product>Profile>Leaks>Profile
memory leak
method
32. 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.
Interface Builder
AppKit
namespace
id
33. 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.
cannot
compile time
receiver
inheritance hierarchy
34. 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.
Edit>Refactor>Convert to Objective-C ARC
asterisk (*)
link time
asynchronous message
35. Same as class object. (first way to say it.)
encapsulation
factory
dereference (dereferencing)
designated
36. Initializer method traditionally begin with the _____ prefix
instance method
cannot
init
developer intent
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.
readwrite
namespace
class object
-
38. In C all functions pass their arguments by ____ which means the compiler makes local copies of those arguments
Binary
value
procedures
Enumerations
39. 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.
reference counting
Unsigned
factory object
strong
40. Objective-C's protocols are really about communicating _____ _______
category
developer intent
floating-point
9
41. Square bracket syntax for calling a method
namespace
fields
designated initializer
[receiver message];
42. Zeroing weak referencing should be used for _____ and data sources to prevent inadvertent retain cycles
dynamic typing
delegates
NSString
Enumerations
43. 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
heap
delegate
inheritance
NSString
44. An object in another application - one that's a potential receiver for a remote message.
NSObject
remote object
adopt
informal protocol
45. ____ provide a concise & elegant method for defining a discrete set of values
Unsigned
printf( )
nil
Enumerations
46. The first index in an array is valued at ____
C operators
namespace
selector
zero
47. Any class that's one step below another class in the inheritance hierarchy.
subclass
anonymous object
fields
strong
48. An object id with a value of 0.
runtime
readwrite
@interface
nil
49. This symbol denotes a method as being a class method
NSObject
+
selector
ampersand (&)
50. 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).
zero
instance variable
Cocoa
implementation