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. ______ data types are always zero or greate
category
Unsigned
precedence
asterisk (*)
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
struct
%
message expression
3. A set of method definitions that is segregated from the rest of the class definition.
nil
message expression
implementation
category
4. In object-oriented programming a procedure that can be executed by an object.
static typing
method
factory object
null
5. 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
strong
conform
dereference (dereferencing)
Unitary
6. Zeroing weak referencing should be used for _____ and data sources to prevent inadvertent retain cycles
delegates
precedence
class
object
7. Objective-C is a _____ of the C language
method
anonymous object
superset
heap
8. 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.
Categories
abstract class
factory
C operators
9. 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.
properties
selector
precedence
link time
10. A ____ ____ is a situation where you free memory and then accidentally continue to use it
delegate
Enumerations
dangling pointer
floating-point
11. A class that's one step above another class in the inheritance hierarchy; the class through which a subclass inherits methods and instance variables.
Smalltalk
superclass
+
Encapsulation
12. In a format string the place holder for an object is ______
interface
message
delegates
%@
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).
implementation
dynamic typing
Interface Builder
instance
14. The _____ function can be used to print a message to the console
heap
printf( )
instance
procedural programming language
15. _____ 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'.
receiver
Encapsulation
procedural programming language
formal protocol
16. A message sent from one application to an object in another application.
remote message
framework
nil
ampersand (&)
17. In a home building analogy a ____ is the blueprint and the object is the house
dispatch table
heap
C operators
class
18. A prototype for a particular kind of object; declares instance variables and defines methods for all members of the class.
outlet
instance
readonly
class
19. The Objective-C runtime table that contains entries that associate method selectors with the class-specific addresses of the methods they identify.
dynamic allocation
pointers
%
dispatch table
20. Each class should have a ______ initializer a single method responsible for performing all of the object's setup and initialization.
Signed
readwrite
null
designated
21. A way to package a logically related set of classes & protocols and functions together with localized strings & online documentation and other pertinent files.
remote object
floating-point
unitary
framework
22. 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.
class object
chars
+
cycles
23. A ____ _____ is where you forget to free up memory
binary
memory leak
NSObject
chars
24. An advanced object-oriented development platform in Mac OS X; a set of frameworks whose primary programming interfaces are in Objective-C.
Cocoa
@interface
Smalltalk
null
25. 3 Common Float data types: float - _____ - CGFloat
instance variable
developer intent
binary
double
26. A language such as C that organizes a program as a set of procedures that have definite beginnings and ends.
dynamic typing
ampersand (&)
dangling pointer
procedural programming language
27. 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.
object
message expression
precedence
encapsulation
28. ____ provide a concise & elegant method for defining a discrete set of values
Product>Profile>Leaks>Profile
protocol
Enumerations
instance method
29. A class is said to do this when it declares that it implements all the methods in the protocol.
cycles
dereference (dereferencing)
id
adopt
30. 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
informal protocol
Pointers
instance
structures
31. ARC is susceptible to retain _____
cycles
floating-point
static typing
method
32. Protocols are adopted by adding a ____________ list of protocols inside angled brackets after the superclass declaration in a class's @interface block
comma-separated
printf( )
copy
AppKit
33. The root class in Objective-C
pointers
NSObject
factory
subclass
34. 7 Common Integer data types: BOOL - char- short - int - long - _____ - NSInteger
long long
properties
Protocols
superset
35. The part of an Objective-C class specification that declares its public interface which includes its superclass name & instances variables and public-method prototypes.
NSObject
+
interface
assign
36. The direct or indirect report of external activity especially user activity on the keyboard and mouse.
instance
null
event
deprecated
37. 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.
%
adopt
delegate
dynamic allocation
38. In object-oriented programming the ability of a superclass to pass its characteristics (methods and instance variables) on to its subclasses.
receiver
dynamic binding
precedence
inheritance
39. _____ data types can be both positive and negative
assign
interface
pointer
Signed
40. Short for mutual exclusion semaphore. An object used to synchronize thread execution.
readwrite
cycles
double
mutex
41. 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.
chars
reference counting
nonatomic
subclass
42. A _______ method is one that is likely to be unsupported in the future. It's use should be discontinued.
developer intent
outlet
memory leak
deprecated
43. 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.
@interface
copy
asynchronous message
instance variable
44. Discovering the class of an object at runtime rather than at compile time.
square brackets
dynamic typing
Protocols
zero
45. Placing a ____ before a normal variable name gives it's address
Protocols
dereference (dereferencing)
interface
ampersand (&)
46. Giving the compiler information about what kind of object an instance is - by typing it as a pointer to a class.
static typing
id
anonymous object
deprecated
47. 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.
memory leak
floating-point
informal protocol
link time
48. Objective-C methods are called using ____ _____
instance
memory leak
namespace
square brackets
49. Objective-C borrows much of its syntax from ______ one of the earliest object-oriented languages
Smalltalk
[receiver message];
Product>Profile>Leaks>Profile
protocol
50. Data types are divided into two main categories: integer and ______
floating-point
interface
id
Edit>Refactor>Convert to Objective-C ARC