Waiting for answer This question has not been answered yet. You can hire a professional tutor to get the answer.

QUESTION

Hello i know its ruby language im sorry but i couldn't find any ruby

C: > Users > farnam > Desktop > Prog > Code > W.rbrequire ' ./input_functions'class Planesattr_accessor :id, :flight, :origin, :destinationdef initialize (id, flight, origin, destination)eid = id@flight = flight8@origin = origin9@destination = destination10end111213end1415# Complete the code below16# Use input_functions to read the data from the user17def read_planes18count = 319plaines = Array . new( )20i = 121while i <= 322plane = read_plane23planes << plane24i +=125end26return planes27end2829def read_plane3031plane_id = read_integer("enter plane id:")plane_flight = read_string("enter flight name: ")32plane_origin = read_string("enter origin airport:")33plane_destination = read_string("enter destination airport:")34plane = Plane. new(plane_id, plane_flight, plane_origin, plane_destination)35plane. id = plane_id36plane. flight = plane_flight37plane. origin = plane_origin38plane. destination = plane_destination39return plane40

Show more
LEARN MORE EFFECTIVELY AND GET BETTER GRADES!
Ask a Question