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. Symbol used to denote a placeholder in a format string
framework
%
instance
encapsulation
2. Property attribute that synthesizes only a getter for the property
procedures
readonly
link time
asterisk (*)
3. A method that can operate on class objects rather than instances of the class.
class method
Interface Builder
readonly
Categories
4. 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.
fields
encapsulation
polymorphism
informal protocol
5. 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
value
instance
dereference (dereferencing)
6. ____ provide a concise & elegant method for defining a discrete set of values
formal protocol
unitary
procedures
Enumerations
7. The nine fundamental building blocks of Objective-C can be dividing into 2 categories: data and _______
informal protocol
procedures
C operators
-
8. Pointers are declared by placing a(n) ___ between the type declaration and the variable name
assign
Unitary
class
asterisk (*)
9. Protocols are adopted by adding a ____________ list of protocols inside angled brackets after the superclass declaration in a class's @interface block
pointer
procedural programming language
comma-separated
attributes
10. A language such as C that organizes a program as a set of procedures that have definite beginnings and ends.
binary
assign
delegate
procedural programming language
11. This symbol denotes a method as being an instance method
designated initializer
C operators
-
%
12. Short for mutual exclusion semaphore. An object used to synchronize thread execution.
class object
mutex
anonymous object
@interface
13. Zeroing weak referencing should be used for _____ and data sources to prevent inadvertent retain cycles
delegates
dangling pointer
Categories
@implementation
14. When creating a class implementation file you begin with the _____ keyword and close with the @end keyword
+
@implementation
Cocoa
factory object
15. Property attribute that causes the setter to store a strong reference to the assigned value
delegates
static typing
runtime
strong
16. 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.
@interface
static typing
asynchronous message
namespace
17. In object-oriented programming - the method selector (name) and accompanying parameters that tell the receiving object in a message expression what to do.
Unsigned
message
procedural programming language
instance variable
18. 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.
asterisk (*)
9
instance
conform
19. The _____ function can be used to print a message to the console
runtime
procedures
printf( )
formal protocol
20. A class is said to do this when it declares that it implements all the methods in the protocol.
init
doubles
message expression
adopt
21. A technique used in C-based languages where the operating system provides memory to a running application as it needs it instead of when it launches.
dynamic allocation
class
NSObject
method
22. 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
@interface
anonymous object
structures
factory
23. 7 Common Integer data types: BOOL - char- short - int - long - _____ - NSInteger
designated
long long
inheritance hierarchy
+
24. The part of an Objective-C class specification that declares its public interface which includes its superclass name & instances variables and public-method prototypes.
@implementation
struct
interface
memory leak
25. In the Objective-C language the declaration of a group of methods not associated with any particular class.
conform
implementation
instance
protocol
26. a+b; is an example of using a _____ operator
inheritance
binary
deprecated
square brackets
27. ARC is susceptible to retain _____
precedence
cycles
ARC
strong
28. Objective-C methods are called using ____ _____
inheritance
assign
square brackets
ampersand (&)
29. In a format string the place holder for an object is ______
factory object
%@
instance variable
event
30. 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.
instance
Signed
inheritance hierarchy
factory
31. The process of setting or reading the value at an address pointed to by a pointer
protocol
dereference (dereferencing)
implementation
floating-point
32. A way to package a logically related set of classes & protocols and functions together with localized strings & online documentation and other pertinent files.
abstract class
Product>Profile>Leaks>Profile
dynamic allocation
framework
33. When creating a class header file you begin with the _____ keyword and close with the @end keyword
init
Edit>Refactor>Convert to Objective-C ARC
@interface
procedural programming language
34. Two additional foundational building blocks of Objective-C distinct from data and procedure type foundations: ________ and Categories/Extensions
cannot
Protocols
%
instance method
35. 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.
unitary
cycles
Unsigned
selector
36. An advanced object-oriented development platform in Mac OS X; a set of frameworks whose primary programming interfaces are in Objective-C.
cycles
Cocoa
nil
assignment
37. Objective-C binds methods and arguments at _____ instead of compile time
Protocols
category
runtime
Binary
38. ______ operators take a single operand
Product>Profile>Leaks>Profile
cannot
fields
Unitary
39. Objective-C's protocols are really about communicating _____ _______
delegates
developer intent
strong
Cocoa
40. 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.
floating-point
conform
heap
formal protocol
41. In object-oriented programming the ability of a superclass to pass its characteristics (methods and instance variables) on to its subclasses.
inheritance
Unsigned
designated initializer
[receiver message];
42. 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.
[receiver message];
reference counting
Encapsulation
dispatch table
43. _____ 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'.
inheritance hierarchy
Unitary
Pointers
Encapsulation
44. An object id with a value of 0.
nil
Unitary
message
static typing
45. A ____ ____ is a situation where you free memory and then accidentally continue to use it
cannot
dangling pointer
chars
object
46. 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
init
assignment
instance method
47. 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.
nonatomic
ampersand (&)
id
outlet
48. 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.
anonymous object
Binary
id
distributed objects
49. Another name for a class that's defined solely so that other classes can inherit from it.
abstract superclass
init
dynamic binding
selector
50. _____ allow indirect access and modification of a variable's value.
Pointers
selector
framework
class object