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. In a format string the place holder for an object is ______
%@
instance
Protocols
null
2. Each class should have a ______ initializer a single method responsible for performing all of the object's setup and initialization.
remote object
designated
informal protocol
superclass
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).
instance method
factory object
implementation
%
4. _____ allow you to add new methods to existing classes
Categories
binary
Product>Profile>Leaks>Profile
protocol
5. Objective-C's protocols are really about communicating _____ _______
developer intent
class
class method
null
6. The time after a program is launched and while it's running. Decisions made at during this time can be influenced by choices the user makes.
ARC
runtime
instance
anonymous object
7. A prototype for a particular kind of object; declares instance variables and defines methods for all members of the class.
class
long long
readwrite
framework
8. 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.
outlet
9
dynamic typing
message expression
9. The part of an Objective-C class specification that declares its public interface which includes its superclass name & instances variables and public-method prototypes.
assignment
interface
memory leak
runtime
10. Property attribute that causes the setter to store a strong reference to the assigned value
mutex
strong
null
asynchronous message
11. The most flexible C data type: ______
message
struct
superclass
comma-separated
12. 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.
Encapsulation
namespace
Unsigned
dynamic binding
13. The Objective-C runtime table that contains entries that associate method selectors with the class-specific addresses of the methods they identify.
dynamic binding
message
chars
dispatch table
14. 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
abstract class
Unitary
designated initializer
assign
15. 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.
encapsulation
factory
cycles
class object
16. A _______ method is one that is likely to be unsupported in the future. It's use should be discontinued.
procedural programming language
heap
deprecated
interface
17. Objective-C binds methods and arguments at _____ instead of compile time
Categories
runtime
dynamic typing
chars
18. Objective-C objects should use strong or weak ______
attributes
pointer
weak
cannot
19. When creating a class implementation file you begin with the _____ keyword and close with the @end keyword
@implementation
pointer
struct
procedural programming language
20. C-style strings are stored in an array of _____
conform
method
chars
Edit>Refactor>Convert to Objective-C ARC
21. Objective-C borrows much of its syntax from ______ one of the earliest object-oriented languages
strong
null
method
Smalltalk
22. Short for mutual exclusion semaphore. An object used to synchronize thread execution.
dynamic allocation
structures
@implementation
mutex
23. ____ provide a concise & elegant method for defining a discrete set of values
@implementation
instance variable
Enumerations
pointers
24. The first index in an array is valued at ____
cannot
zero
id
link time
25. 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.
Unsigned
instance variable
chars
AppKit
26. In object-oriented programming the ability of different objects to respond each in its own way - to the same message.
object
polymorphism
%@
Protocols
27. An architecture that facilitates communication between objects in different address spaces.
procedural programming language
distributed objects
receiver
inheritance hierarchy
28. ARC is susceptible to retain _____
null
Categories
cycles
unitary
29. 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 variable
precedence
inheritance hierarchy
procedures
30. In object-oriented programming the ability of a superclass to pass its characteristics (methods and instance variables) on to its subclasses.
%
inheritance
chars
+
31. There are ____ fundamental building blocks in Objective-C
double
unitary
9
procedural programming language
32. Instance variables are optional in iOS if ________ are used
properties
+
cycles
remote object
33. Procedures (like verbs) are processes that manipulate or transform data and in Objective-C these 3 elements are _____ - functions and methods
Edit>Refactor>Convert to Objective-C ARC
Enumerations
runtime
C operators
34. A way to package a logically related set of classes & protocols and functions together with localized strings & online documentation and other pertinent files.
NSString
framework
synchronous message
double
35. a+b; is an example of using a _____ operator
double
asterisk (*)
id
binary
36. A method that can operate on class objects rather than instances of the class.
abstract class
inheritance
memory leak
class method
37. Any method that can be used by an instance of a class rather than by the class object.
interface
remote message
instance method
9
38. In C all functions pass their arguments by ____ which means the compiler makes local copies of those arguments
value
Interface Builder
@implementation
object
39. A protocol declared as a category usually as a category of the NSObject class.
informal protocol
nonatomic
Unsigned
reference counting
40. The root class in Objective-C
implementation
NSObject
delegate
interface
41. A class that's defined solely so that other classes can inherit from it. Programs don't use instances of this; they use only instances of its subclasses.
asterisk (*)
formal protocol
polymorphism
abstract class
42. Zeroing weak referencing should be used for _____ and data sources to prevent inadvertent retain cycles
delegates
pointer
ARC
asterisk (*)
43. Another name for a class that's defined solely so that other classes can inherit from it.
abstract superclass
inheritance
attributes
readonly
44. ______ data types are always zero or greate
Unsigned
value
Cocoa
cycles
45. Property attribute that causes the setter to store a copy of the assigned value
Protocols
Smalltalk
copy
compile time
46. _____ operators take 2 operands
+
Binary
AppKit
C operators
47. 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.
binary
object
procedural programming language
link time
48. Placing a ____ before a normal variable name gives it's address
ampersand (&)
Unsigned
NSObject
message expression
49. 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.
distributed objects
Binary
NSObject
instance
50. Initializer method traditionally begin with the _____ prefix
instance
subclass
init
message