Ruby \"Everything you need is Ruby 19 Getting started with Ruby & Installation:
ID: 3745882 • Letter: R
Question
Ruby "Everything you need is Ruby 19 Getting started with Ruby & Installation: https://goo.gl/ZXwYMj Recent Searches-Ruby 1) Short questions (30%) 2) Solve a problem with Ruby programming (50%) 3) Documentation (10%) 4) Thinking assignment (10%) 1) Fully implemented Ruby code files (main.rb&search controller.rb) 2) Project document "markdown" file (README.md) 3) Short questions &Thinking problem in one doc/pdf file (homework ruby.docx OR homework.ruby.pdf) 1 Print "Hello World 2) List and describe all data structures supported by Ruby programming language (e.g. List, Dictionary, Set) ) Create an array from 1 to 10 numbers and print an array in console. [CODE 4)Create a dictionary (Hash) of your personal information and print in console. 5) What is class and object in OOP? Explain with appropriate example in brief 6) What is Inheritance, Encapsulation, Abstraction? Explain with appropriate 7) Create an Animal class and its instance with initialize method in Ruby. Also, (e.g. first.name, last.name, tiger email id, banner.id, fav movies) [CODE CODE example in brief. [CODE create some getter-setter methods. (NOTE: be creative and allowed to answer in your way) (CODE 8) What is the difference between attrreader, attr writer, attr_accessor in Ruby?Explanation / Answer
Asnwer)
1. puts "Hello World".
2. Data Structures in Ruby :
3.
numbers = [ 1,2,3,4,5,6,7,8,9,10 ]
puts numbers
Output :
1 2 3 4 5 6 7 8 9 10
4.
hash = { 'fkey' => 'Ruby', 'fvalue' => 'Rails' }
puts hash
Output :
{"fkey"=>"Ruby", "fvalue"=>"Rails"}
Related Questions
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.