using System;
using System.Collections.Generic;
public class Program
{
public class Film
{
public string name;
public string date;
public string type;
public string Name
{
get{return this.name;}
set {this.name = value;}
}
public string Date
{
get{return this.date;}
set {this.date = value;}
}
public string Type
{
get{return this.type;}
set {this.type = value;}
}
public Film ()
{
}
public Film (string movie, string genre, string year)
{
name = movie;
type = genre;
date = year;
}
public override string ToString()
{
return "Movie: " + Name + ", " + "genre - " + Type + ", " + "date " + Type + " year";
}
}
public class Adding
{
public List
<Film
> movies
= new List
<Film
> ();
public List<Film> Movies
{
get{return this.movies;}
set {this.movies = value;}
}
public void HowtoAdd (Film movie1)
{
Adding a2
= new Adding
();
foreach(Film movie in a2.Movies)
{
movies.Add(movie1);
}
}
public void Izvejdane(string command)
{
Adding a3
= new Adding
();
foreach (Film movie3 in a3.Movies)
{
if (command == movie3.Name)
{
a3.HowtoAdd(movie3);
}
if (command == movie3.Type)
{
a3.HowtoAdd(movie3);
}
if (command == movie3.Date)
{
a3.HowtoAdd(movie3);
}
}
foreach(Film element in a3.Movies)
{
string strx = element.ToString();
Console.WriteLine(strx);
}
}
}
public static void Main()
{
for (int i = 0; i<1; i++)
{
Console.Write("Movie:");
a1.Name = Console.ReadLine();
Console.Write("Movie genre:");
a1.Type = Console.ReadLine();
Console.Write("Date:");
a1.Date = Console.ReadLine();
a.HowtoAdd(a1);
}
Console.WriteLine("Command:");
string command1 = Console.ReadLine();
a.Izvejdane(command1);
}
}
{"html5":"htmlmixed","css":"css","javascript":"javascript","php":"php","python":"python","ruby":"ruby","lua":"text\/x-lua","bash":"text\/x-sh","go":"go","c":"text\/x-csrc","cpp":"text\/x-c++src","diff":"diff","latex":"stex","sql":"sql","xml":"xml","apl":"apl","asterisk":"asterisk","c_loadrunner":"text\/x-csrc","c_mac":"text\/x-csrc","coffeescript":"text\/x-coffeescript","csharp":"text\/x-csharp","d":"d","ecmascript":"javascript","erlang":"erlang","groovy":"text\/x-groovy","haskell":"text\/x-haskell","haxe":"text\/x-haxe","html4strict":"htmlmixed","java":"text\/x-java","java5":"text\/x-java","jquery":"javascript","mirc":"mirc","mysql":"sql","ocaml":"text\/x-ocaml","pascal":"text\/x-pascal","perl":"perl","perl6":"perl","plsql":"sql","properties":"text\/x-properties","q":"text\/x-q","scala":"scala","scheme":"text\/x-scheme","tcl":"text\/x-tcl","vb":"text\/x-vb","verilog":"text\/x-verilog","yaml":"text\/x-yaml","z80":"text\/x-z80"}