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. Two additional foundational building blocks of Objective-C distinct from data and procedure type foundations: ________ and Categories/Extensions
dynamic typing
cannot
ampersand (&)
Protocols
2. 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.
dangling pointer
instance
abstract class
category
3. Another name for a class that's defined solely so that other classes can inherit from it.
assignment
selector
nil
abstract superclass
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.
receiver
class object
Product>Profile>Leaks>Profile
id
5. The process of setting or reading the value at an address pointed to by a pointer
subclass
designated
dereference (dereferencing)
strong
6. 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.
selector
compile time
delegates
class object
7. Same as class object. (second way to say it.)
formal protocol
Categories
C operators
factory object
8. Zeroing weak referencing should be used for _____ and data sources to prevent inadvertent retain cycles
attributes
delegates
Smalltalk
precedence
9. Placing a ____ before a normal variable name gives it's address
inheritance
binary
strong
ampersand (&)
10. When creating a class header file you begin with the _____ keyword and close with the @end keyword
attributes
instance
synchronous message
@interface
11. A class is said to do this when it declares that it implements all the methods in the protocol.
adopt
compile time
implementation
static typing
12. ____ provide a concise & elegant method for defining a discrete set of values
delegate
pointer
Enumerations
-
13. 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
superset
Unsigned
implementation
14. Property attribute that causes the setter to store a copy of the assigned value
pointer
readonly
polymorphism
copy
15. The direct or indirect report of external activity especially user activity on the keyboard and mouse.
struct
event
selector
printf( )
16. a+b; is an example of using a _____ operator
dangling pointer
dynamic allocation
binary
ARC
17. The first index in an array is valued at ____
%
encapsulation
dangling pointer
zero
18. A prototype for a particular kind of object; declares instance variables and defines methods for all members of the class.
class
remote object
%@
readonly
19. If you are compiling an application with ARC (Automatic reference Counting) you _______ store Objective-C objects inside a struct
category
formal protocol
cannot
implementation
20. Xcode sequence to examine an app for memory leaks or retain cycles
Protocols
binary
assign
Product>Profile>Leaks>Profile
21. In a home building analogy a ____ is the blueprint and the object is the house
Unsigned
class
NSString
Enumerations
22. An object of unknown class. Interface is published through protocol declaration.
value
anonymous object
framework
heap
23. 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.
selector
delegates
namespace
outlet
24. _____ allow you to add new methods to existing classes
ampersand (&)
Categories
static typing
Interface Builder
25. 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
selector
inheritance hierarchy
@interface
26. Instance variables are optional in iOS if ________ are used
formal protocol
properties
instance method
outlet
27. Property attribute that synthesizes both a getter and setter for the property
readwrite
readonly
link time
method
28. 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.
Signed
implementation
instance
formal protocol
29. An object in another application - one that's a potential receiver for a remote message.
class
NSObject
Enumerations
remote object
30. a++; is an example of using a _____ operator
remote message
nil
synchronous message
unitary
31. In the Objective-C language the declaration of a group of methods not associated with any particular class.
dereference (dereferencing)
readwrite
protocol
Cocoa
32. A compiler feature that provides automated memory management
ARC
instance method
@interface
class
33. 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.
NSString
Categories
dynamic allocation
subclass
34. 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
NSString
weak
conform
ampersand (&)
35. 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.
informal protocol
assignment
link time
[receiver message];
36. Property attribute that synthesizes only a getter for the property
superset
interface
deprecated
readonly
37. To destroy an object set the variable that points to it to _____
adopt
double
Unsigned
nil
38. The time when source code is compiled; constrained by the amount and kind of information encoded in source files.
compile time
chars
printf( )
superset
39. Property attribute that causes the setter to store a zeroing weak reference to the assigned value
Smalltalk
weak
designated initializer
properties
40. The 6 main categories of operators are: ____ - arithmetic - comparison - logical - bitwise and membership
NSObject
assignment
heap
Edit>Refactor>Convert to Objective-C ARC
41. C-style strings always end with a ____ character
asynchronous message
null
Binary
outlet
42. In C all functions pass their arguments by ____ which means the compiler makes local copies of those arguments
value
structures
unitary
Signed
43. 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.
interface
class object
deprecated
reference counting
44. 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.
inheritance hierarchy
properties
interface
distributed objects
45. In object-oriented programming a procedure that can be executed by an object.
Enumerations
framework
method
namespace
46. In object-oriented programming the ability of different objects to respond each in its own way - to the same message.
polymorphism
precedence
+
Product>Profile>Leaks>Profile
47. A ____ ____ is a situation where you free memory and then accidentally continue to use it
attributes
dangling pointer
readwrite
dynamic typing
48. The _____ function can be used to print a message to the console
factory object
message expression
printf( )
memory leak
49. Xcode sequence to convert non-ARC apps to ARC
Edit>Refactor>Convert to Objective-C ARC
Enumerations
class object
method
50. Objective-C's protocols are really about communicating _____ _______
developer intent
anonymous object
static typing
printf( )