SUBJECTS
|
BROWSE
|
CAREER CENTER
|
POPULAR
|
JOIN
|
LOGIN
Business Skills
|
Soft Skills
|
Basic Literacy
|
Certifications
About
|
Help
|
Privacy
|
Terms
Search
Test your basic knowledge |
Ruby Programming Vocab
Start Test
Study First
Subject
:
it-skills
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. a collection of characters such as "Hello world!"
W
string
Z
call
2. Boolean AND operator
class
.sub
&&
kernel
3. a set of code within a class or object
method
.pop
not and or
library
4. an array method that returns TRUE or FALSE if the array contains specified item
start_with?
.include?()
operators
object
5. mixing expressions into strings
if?then:else
%q
Z
interpolation
6. a single instance of a class.
flow control
d
object
not and or
7. less than or equal to (comparison operator)
=>
.between?
<=
@@
8. used in an expression to manipulate objects
local variable
ARGV
operators
iterator
9. comparison operator for "not equal to"
$:.
.each
!=
.next
10. data passed to methods in parenthesis after a method's name.
%
.sort
object orientation
parameters
11. assigns a key to a hash value
Z
.pop
=>
<=
12. a string method that capitalizes first character
?x
%w{}
.even?
.capitalize
13. array method that transforms the contents of an array according to a specified set of rules
if?then:else
s
code blocks
.map
14. returns ASCII value of x
class
?x
.next
.scan()
15. allows for classes to relate to each other in a hierarchy
#{}
.capitalize
inheritance
%w{}
16. a section of code with no discrete name which is not a method by itself that can be called upon and can receive an argument.
.next
code blocks
call
|x|
17. a fixed value that begins with a capital letter such as Pi.
constant
.match
^
w
18. passes value into block of code and assigns it the label of "x"
|x|
ARGV
kernel
%w{}
19. comaprison operator that will read 0 if = or 1 if higher or -1 if lower.
!=
<=>
integer
.even?
20. an array method that returns TRUE or FALSE if the array contains specified item
<
.include?()
.downcase
@
21. a regular method that is the anchor for the beggining of a line
.include?()
class
^
.pop
22. tells ruby a value to pass while iterating a block of code
.chop
%
yield
.scan()
23. a special array made from arguments that were added to the command line at start up.
object
s
.gsub
ARGV
24. a string method that substituition. Requires 2 arguments.
.sub
.upcase
.chop
regular expressions
25. method that tells an argument's place value within an array
D
arguments
.index
.chop
26. a string method that capitalizes first character
#{}
.index
.scan()
.capitalize
27. a collection of objects with a defined order
array
%arg
!
@@
28. a placeholder for a single object that may be a number or string or list or instance of a defined class
yield
variable
.methods
s
29. a string method that makes string all caps.
flow control
.include?()
string
.upcase
30. method to determine if an object is an even number
.scan()
.even?
object orientation
.next
31. (regular expression)any nonletter or nondigit or nonunderscore.
A
?x
W
.index
32. string method that determines if a string ends with a defined string
end_with?
.even?
kernel
#{}
33. (regular expression)any letter or digit or underscore
S
class
interpolation
w
34. the representation of data from a start to end point
S
range
.pop
<<
35. a string method that substitutes ALL occurrences of a string with another.
.gsub
!
$
.swapcase
36. interpolation operator
#{}
.scan()
not and or
|x|
37. array method that removes last item from an array
.pop
flow control
%
!
38. conditionally stops a loop
.next
break if
constant
class
39. interpolation operator
#{}
regular expressions
A
constant
40. the ternary operator if?then:else
.between?
$:.
code blocks
if?then:else
41. (regular expression)anchor for the start of a string
A
%arg
Z
flow control
42. a number with a decimal point such as 1.0 or 3.1
iterator
code blocks
float
W
43. defines array of multiple elements seperated by a space
%w{}
<<
.map
.chop
44. a variable that lists the directories where Ruby will look for libraries
<<
start_with?
<<
$:.
45. method that sorts items alphabetically
.sort
A
.methods
local variable
46. returns ASCII value of x
A
?x
if?then:else
<<
47. (regular expression)any non-whitespace character
ARGV
S
.methods
.sort
48. comparison operator for "equal to"
arguments
A
==
^
49. (regular expression)any nondigit
strip
@@
%
D
50. tells you all methods that an object may invoke.
.methods
.between?
ARGV
|x|