static void Main() { string title = Console.ReadLine(); string author = Console.ReadLine(); int price = int.Parse(Console.ReadLine()); Book new_novel = new MyBook(title, author, price); new_novel.display(); }
static void Main(string[] args) { Console.Write("Title: "); string title = Console.ReadLine(); Console.Write("Author: "); string author = Console.ReadLine(); Console.Write("Price: "); int price = Convert.ToInt32(Console.ReadLine()); Console.WriteLine(); Book newNovel = new MyBook(title, author, price); newNovel.Display(); }