What will be the output of the following? "Eric".irreverse a) Eric b) cirE c) undefined method d) none of the mentioned
View Question
What is the output of the following?
ruby.reverse
What is the output of the following? ruby.reverse a) Error in compilation b) ybur c) 4 d) ...
View Question
What is the output of the following?
“Iam learning ruby language”.length
What is the output of the following? "Iam learning ruby language".length a) 26 b) 23 c) 20
View QuestionThe .length method is used to check number of characters.
a) True b) False Answer: b Explanation: The .length method is used to check number of characters, ...
View QuestionWhich of the following is the valid string method?
a) The .length method b) The .upcase method c) The .downcase method d) The .irreverse method Answer: ...
View Question
What is the output of the given code?
Ans=Ruby
puts “#[Ans] is an oop language”
What is the output of the given code? Ans=Ruby puts "#[Ans] is an oop ...
View Question
What is the output of the given code?
Ans=Ruby
puts “#{Ans} is an oop language”
puts “It is very efficient langauge”
puts “#{expr} is used on rails platform”
What is the output of the given code? Ans=Ruby puts "#{Ans} is an oop ...
View Question
What is the output of the the given code?
puts “My name is #{Name}”
What is the output of the the given code? puts "My name is #{Name}" a) Error ...
View Question
What is the output of the given code?
print “What’s your address”
city,state,pin=gets.chomp,gets.chomp,gets.chomp
puts “Iam from #{city} city, #{state} state, pincode: #{pin} “
What is the output of the given code? print "What's your address" city,state,pin=gets.chomp,gets.chomp,gets.chomp ...
View Questionfirst_name,Last_name=gets.chomp,gets.chomp is the correct way to get the input from the user.
a) True b) False Answer: a Explanation: It will take the input from user and store its value in ...
View Question