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 general type for any kind of object regardless of class; defined as a pointer to an object data structure; can be used for both class objects and instances of a class.
id
@interface
%
inheritance hierarchy
2. 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).
Edit>Refactor>Convert to Objective-C ARC
compile time
message expression
designated initializer
3. The 6 main categories of operators are: ____ - arithmetic - comparison - logical - bitwise and membership
attributes
weak
static typing
assignment
4. 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.
static typing
class object
remote object
Protocols
5. An advanced object-oriented development platform in Mac OS X; a set of frameworks whose primary programming interfaces are in Objective-C.
message
dispatch table
comma-separated
Cocoa
6. An object that acts on behalf of another object.
readonly
unitary
instance
delegate
7. The process of setting or reading the value at an address pointed to by a pointer
-
square brackets
long long
dereference (dereferencing)
8. Consider: [NSString alloc]. 'alloc' is an example of a(n) class method rather than a _______ method
instance
link time
developer intent
instance variable
9. Objective-C objects should use strong or weak ______
doubles
attributes
remote message
procedural programming language
10. To destroy an object set the variable that points to it to _____
nil
@interface
weak
dynamic allocation
11. The _____ function can be used to print a message to the console
dangling pointer
comma-separated
inheritance
printf( )
12. Any method that can be used by an instance of a class rather than by the class object.
assign
printf( )
factory
instance method
13. Initializer method traditionally begin with the _____ prefix
Categories
conform
init
dispatch table
14. 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.
Binary
namespace
inheritance hierarchy
Enumerations
15. Pointers are declared by placing a(n) ___ between the type declaration and the variable name
informal protocol
class object
assignment
asterisk (*)
16. A set of method definitions that is segregated from the rest of the class definition.
cycles
asterisk (*)
category
[receiver message];
17. ______ operators take a single operand
Unitary
runtime
encapsulation
dangling pointer
18. The time when source code is compiled; constrained by the amount and kind of information encoded in source files.
compile time
binary
instance
weak
19. When creating a class implementation file you begin with the _____ keyword and close with the @end keyword
formal protocol
binary
namespace
@implementation
20. There are ____ fundamental building blocks in Objective-C
printf( )
Unsigned
copy
9
21. In Objective-C floats are more commonly used than ______
doubles
dynamic binding
event
factory object
22. Discovering the class of an object at runtime rather than at compile time.
properties
dynamic typing
designated
link time
23. A protocol declared as a category usually as a category of the NSObject class.
mutex
unitary
informal protocol
weak
24. 7 Common Integer data types: BOOL - char- short - int - long - _____ - NSInteger
method
assign
printf( )
long long
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.
id
object
conform
heap
26. 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.
runtime
namespace
synchronous message
value
27. Zeroing weak referencing should be used for _____ and data sources to prevent inadvertent retain cycles
namespace
remote object
delegates
static typing
28. The first index in an array is valued at ____
ampersand (&)
zero
inheritance hierarchy
designated initializer
29. a+b; is an example of using a _____ operator
subclass
9
binary
distributed objects
30. ARC is susceptible to retain _____
cycles
square brackets
remote message
Unsigned
31. Xcode sequence to examine an app for memory leaks or retain cycles
inheritance
reference counting
Product>Profile>Leaks>Profile
assignment
32. _____ data types can be both positive and negative
encapsulation
readonly
long long
Signed
33. Same as class object. (first way to say it.)
dereference (dereferencing)
factory
method
fields
34. Another name for a class that's defined solely so that other classes can inherit from it.
Interface Builder
informal protocol
pointer
abstract superclass
35. The most flexible C data type: ______
C operators
link time
struct
message
36. Square bracket syntax for calling a method
properties
Pointers
protocol
[receiver message];
37. A message sent from one application to an object in another application.
remote message
designated initializer
pointers
dangling pointer
38. In object-oriented programming a procedure that can be executed by an object.
method
id
runtime
Product>Profile>Leaks>Profile
39. Objective-C borrows much of its syntax from ______ one of the earliest object-oriented languages
reference counting
Product>Profile>Leaks>Profile
Smalltalk
adopt
40. Objective-C methods are called using ____ _____
@interface
square brackets
Signed
ampersand (&)
41. Data types are divided into two main categories: integer and ______
adopt
floating-point
copy
mutex
42. In a format string the place holder for an object is ______
double
readwrite
%@
procedural programming language
43. 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.
pointer
class
method
AppKit
44. This symbol denotes a method as being an instance method
conform
asterisk (*)
pointer
-
45. Property attribute that causes the setter to store a copy of the assigned value
pointer
conform
@implementation
copy
46. a++; is an example of using a _____ operator
strong
heap
category
unitary
47. Xcode sequence to convert non-ARC apps to ARC
Edit>Refactor>Convert to Objective-C ARC
readwrite
Categories
delegates
48. ______ data types are always zero or greate
Unsigned
inheritance hierarchy
9
%@
49. Any variable that's part of the internal data structure of an instance; declared in a class definition and become part of all objects that are members of or inherit from the class.
instance variable
precedence
square brackets
readonly
50. Property attribute that synthesizes accessors that are not thread safe
nonatomic
strong
comma-separated
weak