rakcode1998

Untitled

Mar 11th, 2017
59
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 2.13 KB | None | 0 0
  1. #include <bits/stdc++.h>
  2.  
  3. typedef long long ll;
  4. typedef long double ld;
  5.  
  6. #define ipow(a,b)+0.5 (int)pow(a,b)
  7. #define pb push_back
  8. #define mp make_pair
  9. #define MOD 1000000007
  10. #define fi first
  11. #define se second
  12. #define pll pair<ll,ll>
  13.  
  14. #define rep(i,n) for(int i=0;i<n;i++)
  15. #define reps(i,a,b) for(int i=a;i<=b;i++)
  16.  
  17. template<typename X> inline X abs(const X& a) { return (a < 0 ? -a : a); }
  18. template<typename X> inline X sqr(const X& a) { return (a * a); }
  19.  
  20. class Pair
  21. {
  22. private :
  23.      int edge;
  24.      int weight;
  25.      int color;
  26. public :
  27.      Pair(int edge , int weight , int color)
  28.      {
  29.          this->edge=edge;
  30.          this->weight=weight;
  31.          this->color=color;
  32.      }
  33.  
  34.      int getedge()
  35.      {
  36.          return edge;
  37.      }
  38.  
  39.      int getweight()
  40.      {
  41.          return weight;
  42.      }
  43.  
  44.      int getcolor()
  45.      {
  46.          return color;
  47.      }
  48.  
  49.      void setedge(int edge)
  50.      {
  51.          this->edge=edge;
  52.      }
  53.  
  54.      void setweight(int weight)
  55.      {
  56.          this->weight=weight;
  57.      }
  58.  
  59.      void setcolor(int color)
  60.      {
  61.          this->color=color;
  62.      }
  63. };
  64.  
  65. struct comp
  66. {
  67.     bool operator() (Pair a, Pair b)
  68.     {
  69.         if(a.getedge()<b.getedge())
  70.         return true;
  71.         else if (a.getedge()>b.getedge())
  72.         return false;
  73.         else
  74.         {
  75.             if(a.getweight()<b.getweight())
  76.             return true;
  77.             else
  78.             return false;
  79.         }
  80.     }
  81. };
  82.  
  83. const ld EPS = ld(1e-9);
  84. const ld PI = ld(3.1415926535897932384626433832795);
  85.  
  86. ll n,C,s,q,t,from,to,w,c,m;
  87.  
  88. const ll mod=LLONG_MAX;
  89.  
  90. vector <Pair> store [100005];
  91. set <Pair,comp> a;
  92. map  <long long , long long > res;
  93.  
  94. using namespace std;
  95. class Task
  96. {
  97. public:
  98.     void solve(istream& in,ostream& out)
  99.     {
  100.     //    freopen("input.txt","r",stdin);
  101.     //      freopen("output.txt","w",stdout);
  102.     //    fclose(stdout);
  103.     }
  104. };
  105.  
  106.  
  107. int main()
  108. {
  109.     ios_base::sync_with_stdio(false);
  110.     cin.tie(NULL);
  111.     cout.tie(NULL);
  112.     Task solver;
  113.     std::istream& in(std::cin);
  114.     std::ostream& out(std::cout);
  115.     solver.solve(in,out);
  116.     out.flush();
  117.  
  118.     return 0;
  119. }
Add Comment
Please, Sign In to add comment