Skip to content
Snippets Groups Projects
Select Git revision
  • ded876b22b8052635bf07f56de915c321dea8580
  • master default protected
2 results

vector.c

Blame
  • MyDate.java 814 B
    public class MyDate{
    
      private int day;
      private int month;
      private int year;
    
      private Time from;
      private Time to;
    
      public MyDate(int[] date, int[] from, int[] to){
        this.day = date[0];
        this.month = date[1];
        this.year = date[2];
    
        this.from = new Time(from[0], from[1]);
        this.to = new Time(to[0], to[1]);
      }
    
      public int get_day(){
        return this.day;
      }
    
      public int get_month(){
        return this.month;
      }
    
      public int get_year(){
        return this.year;
      }
    
      public int[] get_t_from(){
        int[] table = {this.from.hour, this.from.minutes};
        return table;
      }
    
      public int[] get_t_to(){
        int[] table = {this.to.hour, this.to.minutes};
        return table;
      }
    
    }
    
    class Time{
      int hour;
      int minutes;
    
      Time(int h, int m){
        this.hour = h;
        this.minutes = m;
      }
    }