LoginSignup
0
1

More than 3 years have passed since last update.

競技プログラミング練習記 No.1

Last updated at Posted at 2020-06-07

はじめに

シンプルでスマートなコードを目指して書いています。参考になれば幸いです!

競技プログラミングをやっているので、コンテストへの練習や参加で解いた問題を書きます。
AtCoderがほとんどで、ときどきAOJを解きます。

AtCoder
https://atcoder.jp/users/gummy

AOJ
http://judge.u-aizu.ac.jp/onlinejudge/user.jsp?id=choco

主に自分の復習が目的で、気が向いたときに記事を書くことにしています。
問題を解く = 記事の投稿 となってしまうと、問題を解くことへのハードルが上がってしまうからです。

コンテストの問題を全て解くわけではなく、解けたところまでを記事にします。

ABC172で緑コーダーにあがりました!
水色コーダーを目指しています。

ARC106で水コーダーにあがりました! (2020/10/24)
次は青コーダーを目指します。

c++で、以下のプログラムを共通で使っています。

#include <bits/stdc++.h>

#define fastio ios_base::sync_with_stdio(false);cin.tie(NULL);cout.tie(NULL);
#define endl "\n"
#define rep(i,n) repi(i,0,n)
#define repi(i,a,n) for(ll i=a;i<(ll)n;++i)
#define repe(i,n) repie(i,0,n)
#define repie(i,a,n) for(ll i=a;i<=(ll)n;++i)
#define ALL(a) (a).begin(),(a).end()
#define RALL(a) (a).rbegin(),(a).rend()

using namespace std;
using ll = long long;
using P = pair<ll, ll>;
void YN(bool a) { cout << (a ? "Yes" : "No") << endl; }
template<class T> inline bool chmax(T& a, T b) { if (a < b) { a = b; return true; } return false; }
template<class T> inline bool chmin(T& a, T b) { if (a > b) { a = b; return true; } return false; }
void show(){ cout << endl; }
template <class Head, class... Tail>
void show(Head&& head, Tail&&... tail){ cout << head << " "; show(std::forward<Tail>(tail)...); }
template<class T> inline void show(T& begin, T& end) { for(auto itr = begin; itr != end; ++itr) cout<<(*itr)<<" "; cout<<endl; }
template<class T> inline void showall(T& a) { for(auto v:a) cout<<v<<" "; cout<<endl; }

void solve()
{

}

int main()
{
  fastio;
  solve();

  return 0;
}

初回はここまで。
ありがとうございます。

0
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
1