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. (regular expression)any nonletter or nondigit or nonunderscore.
!
.upcase
.scan()
W
2. operator for "Boolean not"
d
!
string
.scan()
3. the remainder operator
>=
||
%
.chop
4. a string method that removes last character
.index
|x|
.chop
?x
5. a string method that capitalizes first character
.split
operators
object orientation
.capitalize
6. (regular expression)any letter or digit or underscore
w
variable
constant
.capitalize
7. a string method that substitutes ALL occurrences of a string with another.
integer
.capitalize
.gsub
!
8. method that sorts items alphabetically
d
^
.sort
@@
9. pushes a new item onto the end of an array.
s
&&
.methods
<<
10. Boolean OR operator
||
operators
W
.sub
11. a string method that scans object for arguments - uses regular expressions.
A
?x
.scan()
.pop
12. a collection of characters such as "Hello world!"
.gsub
break if
call
string
13. an array method that returns TRUE or FALSE if the array contains specified item
.include?()
.capitalize
W
.pop
14. (regular expression)anchor for the end of a string
integer
strip
Z
constant
15. (regular expression)any digit
d
.include?()
$:.
=>
16. a string method that scans object for arguments - uses regular expressions.
#{}
.between?
arguments
.scan()
17. string method that "cleans" extra spaces from strings
$
%q
strip
$
18. a collection of objects or values with associated keys
hash
d
<
.index
19. a special array made from arguments that were added to the command line at start up.
class
ARGV
$:.
array
20. conditionally stops a loop
W
break if
.sort
!=
21. sets a single character text delimiter for multi-line strings
!=
.map
%
%q
22. mixing expressions into strings
!=
.scan()
interpolation
constant
23. an array method that
.each
.gsub
W
@@
24. a set of code within a class or object
method
interpolation
!=
@@
25. tells you all methods that an object may invoke.
object orientation
Z
.methods
|x|
26. (regular expression)any digit
.downcase
.map
#{}
d
27. (regular expression)any nonletter or nondigit or nonunderscore.
%q
string
.scan()
W
28. a special class that holds attributes and data but no methods.
struct
!
S
hash
29. a definition of a concept in an object oriented language.
.even?
.gsub
Z
class
30. array method that removes last item from an array
.select
@@
.pop
$
31. symbol for a global variable which can be called from anywhere in an application.
|x|
>=
?x
$
32. a way to describe patterns in text
if?then:else
break if
regular expressions
class
33. (regular expression)any letter or digit or underscore
s
w
object
<<
34. a number with a decimal point such as 1.0 or 3.1
=>
.map
?x
float
35. 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.
not and or
code blocks
class
%
36. a fixed value that begins with a capital letter such as Pi.
.downcase
parameters
string
constant
37. (regular expression)any space or tab or newline or whitespace
%arg
s
$
.next
38. defines an instance variable which only exists within the object it was created in.
!=
@
!
parameters
39. tells ruby a value to pass while iterating a block of code
yield
.capitalize
regular expressions
@@
40. a string method that splits a string into an array
flow control
not and or
break if
.split
41. variable that can be used only where it is defined within an application
not and or
W
local variable
operators
42. a string method (with /REGEX/ and starting_point separated by comma) that outputs the first string matching the defined regular expression from an optionally defined starting point
variable
.map
.match
.map
43. method that tells an argument's place value within an array
.index
.between?
break if
^
44. comparison operator for "not equal to"
object
!=
range
kernel
45. a string method that changes last character to next alphabetical character
start_with?
.swapcase
.split
.next
46. method to determine if an object is an even number
class
class
!=
.even?
47. a string method that substitutes ALL occurrences of a string with another.
s
.gsub
.each
.sub
48. method to determine if an object is an even number
.upcase
||
.even?
^
49. a module of classes and or functions
D
Z
S
library
50. a string method that substitutes THE FIRST occurrence of a string within a string
>=
^
.sub
.sort