SUBJECTS
|
BROWSE
|
CAREER CENTER
|
POPULAR
|
JOIN
|
LOGIN
Business Skills
|
Soft Skills
|
Basic Literacy
|
Certifications
About
|
Help
|
Privacy
|
Terms
|
Email
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. used in an expression to manipulate objects
integer
class
.sub
operators
2. a number with a decimal point such as 1.0 or 3.1
float
inheritance
.sub
!=
3. interpolation operator
#{}
A
float
library
4. (regular expression)any digit
constant
d
s
!=
5. Boolean not and or (lower preference)
D
.index
!=
not and or
6. less than or equal to (comparison operator)
.next
<=
$
constant
7. string method that "cleans" extra spaces from strings
$:.
!
strip
.downcase
8. a whole number
class
inheritance
code blocks
integer
9. tells you all methods that an object may invoke.
<<
^
.methods
.next
10. data passed to methods in parenthesis after a method's name.
.between?
operators
parameters
variable
11. returns ASCII value of x
.capitalize
?x
constant
class
12. a special array made from arguments that were added to the command line at start up.
%q
#{}
code blocks
ARGV
13. the ternary operator if?then:else
if?then:else
s
.each
|x|
14. methods that step through lists element by element (like each or upto or times etc)
iterator
.include?()
Z
s
15. a string method that scans object for arguments - uses regular expressions.
arguments
.scan()
.gsub
|x|
16. Boolean OR operator
.index
||
constant
W
17. method that sorts items alphabetically
.sort
A
struct
.gsub
18. a string method that substitutes THE FIRST occurrence of a string within a string
<
.include?()
.sub
D
19. a collection of characters such as "Hello world!"
<
!
flow control
string
20. a variable that lists the directories where Ruby will look for libraries
$:.
variable
d
.scan()
21. the remainder operator
.capitalize
yield
D
%
22. (regular expression)any non-whitespace character
float
<<
S
%w{}
23. a special class that holds attributes and data but no methods.
struct
^
%
s
24. (regular expression)anchor for the start of a string
A
struct
constant
<
25. Data type that is assigned at initialization and typically does not change. Starts with a capital letter.
.next
constant
.sort
method
26. a string method that removes last character
!
.chop
.scan()
W
27. array assignment oprator
.each
.chop
inheritance
<<
28. (regular expression)any nondigit
D
.select
.sub
?x
29. 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.
end_with?
class
code blocks
array
30. (regular expression)any digit
d
method
.capitalize
library
31. a string method that capitalizes first character
.capitalize
ARGV
struct
$:.
32. (regular expression)any non-whitespace character
A
string
S
.pop
33. defines an instance variable which only exists within the object it was created in.
@
|x|
.between?
.downcase
34. interpolation operator
Z
variable
.methods
#{}
35. an array method that returns TRUE or FALSE if the array contains specified item
^
.include?()
Z
.scan()
36. comaprison operator that will read 0 if = or 1 if higher or -1 if lower.
<=>
.upcase
.between?
constant
37. a string method that scans object for arguments - uses regular expressions.
%
.scan()
end_with?
s
38. (regular expression)any nonletter or nondigit or nonunderscore.
%arg
yield
W
.downcase
39. an array method that
.each
struct
constant
S
40. the representation of data from a start to end point
regular expressions
operators
range
$
41. a string method that changes last character to next alphabetical character
.next
.between?
.chop
end_with?
42. a string method that makes string all caps.
array
.upcase
.swapcase
.methods
43. method that tells an argument's place value within an array
.next
break if
constant
.index
44. a string method that capitalizes first character
.capitalize
.next
class
kernel
45. (regular expression)any space or tab or newline or whitespace
.map
s
object
.even?
46. greater than or equal to (comparison operator)
>=
.scan()
!=
^
47. (regular expression)any letter or digit or underscore
.select
S
.split
w
48. a string method that uncapitalizes first character
.gsub
.downcase
s
A
49. an array method that returns TRUE or FALSE if the array contains specified item
.include?()
.upcase
Z
!=
50. variable that can be used only where it is defined within an application
class
.sort
local variable
?x