https://codeforces.com/contest/1334/problem/A
ゲームの2つの stats - number of play
(np) と number of clear
(nc) は、以下の条件を すべて 満たさなければならない
- A) np は単調増加である
- B) nc は単調増加である
- C) nc の変化量 は np の変化量以下である
https://codeforces.com/contest/1334/problem/A
ゲームの2つの stats - number of play
(np) と number of clear
(nc) は、以下の条件を すべて 満たさなければならない
https://codeforces.com/contest/1297/problem/B
区間の重なりを O(C+T) で解く方法として、 いもす法 が知られているが、この問題では T が 10^9 に達するため、いもす法では解くことが出来ない。
この問題で数えるべき「区間の重なりの数が1」の区間は、区間の端っことその前後に属する区間の数を数えることで、O(C^2) で数えることができる。
本番ではいもす法では解けないことを理解していたので、区間を重ねてみて冷静に観察すれば解けた... はずである(´ー`; )
fun oneInRange(arr: ArrayList<Pair<Int, Int>>, pos: Int): Boolean {
import kotlin.math.* | |
fun main() { | |
val firstline = readLine()!!.split(" ") | |
val k = firstline[1].toLong() | |
val arr = readLine()!!.split(" ").map { it.toLong() } | |
var pairlist = mutableListOf<Pair<Long, Int>>() | |
for ((idx, value) in arr.withIndex()) { | |
pairlist.add(Pair(value, idx)) |
Index: src/mainwindow.c | |
=================================================================== | |
--- src/mainwindow.c (revision 3616) | |
+++ src/mainwindow.c (working copy) | |
@@ -481,7 +481,9 @@ | |
static void next_labeled_cb (MainWindow *mainwin, | |
guint action, | |
GtkWidget *widget); | |
- | |
+static void latest_cb (MainWindow *mainwin, |
コンテスト名そのものにもリンクを貼ってもらえると嬉しいです。
たとえば 「Codeforces Round #555 (Div. 3)」のテキストに、https://codeforces.com/contest/1157 へのリンクを張るという具合です。
バーチャルコンテストへのリンク (*1) もあるとなお嬉しかったりしますが、UI的に微妙になるかもしれない。。
# Insert your preferred key mappings here. | |
unmapAll | |
map j scrollDown | |
map k scrollUp | |
map l scrollRight | |
map h scrollLeft | |
map gg scrollToTop | |
map G scrollToBottom |
javascript:var elms=document.getElementsByTagName('a');for(var i=0;i<elms.length;i++){elms[i].setAttribute('target','_blank');} |
Git 版 Courier IMAP をビルドし、起動する方法のメモ
courier-unicode は、以下の方法でビルドし、インストールしておく
$ git clone https://github.com/svarshavchik/courier-libs
$ cd courier-libs/unicode
$ autoheader
$ aclocal
ここでは、下記チケットの対応方針について述べる
svarshavchik/courier#10
couriertls(1) には client モードと server モードがある。
client モードは、 couriertls が TLSクライアントとして動作するときのモードを実装するものである。server モードはその対になるもので、courirertls がサーバとして動作するときのモードを実装するものである。