ABC-261-Tutorial
Atcoder Beginner Contest 261 By xiaruize A - Intersection 签到题,强烈推荐写暴力, 不要用数学!!! 不要用数学!!! 不要用数学!!! 不要问我怎么知道的qwq Code 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960// Problem: A - Intersection// Contest: AtCoder - AtCoder Beginner Contest 261// URL: https://atcoder.jp/contests/abc261/tasks/abc261_a// Memory Limit: 1024 MB// Time Limit: 2000 ms//// Powered by CP Editor (https://cpeditor.org)/* Name: ...
Codeforces 1709 Div.2
Educational Codeforces Round 132 (Rated for Div. 2) By xiaruize 题目名突现Minecraft,莫名喜感,放上Creeper aw man一首 A. Three Doors 问题有解,当且仅当递归访问可以遍历所有的点 Code 12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364// Problem: A. Three Doors// Contest: Educational Codeforces Round 132 (Rated for Div. 2)// URL: https://codeforces.com/contest/1709/problem/A// Memory Limit: 256 MB// Time Limit: 2000 ms//// Powere ...
Codeforces-Round-809-Div2-Tutorial
Codeforces Round 809(Div.2) By xiaruize A. Another String Minimization Problem 贪心,考虑优先改左侧的,如果左侧已经为A,则修改右侧的 12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485// Problem: A. Another String Minimization Problem// Contest: Codeforces Round #809 (Div. 2)// URL: https://codeforces.com/contest/1706/problem/A// Memory Limit: 256 MB// Time Limit: 1000 ms//// Powered by CP Editor (https://cpedi ...
Graph
图论 图论 (Graph theory) 是数学的一个分支,图是图论的主要研究对象。图 (Graph) 是由若干给定的顶点及连接两顶点的边所构成的图形,这种图形通常用来描述某些事物之间的某种特定关系。顶点用于代表事物,连接两顶点的边则用于表示两个事物间具有这种关系。 什么是图? 无向图 像这样的是一个无向图 有向图 像这样的是一个有向图 带权图 像这样的是一个带权图 其他基础知识 度数 有几条边连接当前节点 特别对于有向图 入度 指向当前节点的边的数量 出度 从当前节点指向别的节点的边的数量 简单图 简单图指没有“自环和重边”的图 自环 有一个或多个节点有边指向自身的图被称为有自环 重边 两点之间出现两条边(有向图要求是同向的) 存图 常见的存图方式以下几种: 直接存边 很暴力低效,说白了就是把读入数据原封不动的存下来 但是在像Kruskal这种算法中也有应用 邻接矩阵 二维数组Gi,j=0G_{i,j}=0Gi,j​=0表示没有边,否则Gi,jG_{i,j}Gi,j​存边权或0,10,10,1表示有没有边 邻接表 邻接表,通过一个vector存 ...
ABC-260-Tutorial
Atcoder Beginner Contest 260 Tutorial By xiaruize A - A Unique Letter 签到题 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192// Problem: A - A Unique Letter// Contest: AtCoder - AtCoder Beginner Contest 260// URL: https://atcoder.jp/contests/abc260/tasks/abc260_a// Memory Limit: 1024 MB// Time Limit: 2000 ms//// Powered by CP Editor (https://cpeditor.org)/* Name: Au ...
ABC-254-Tutorial
AtCoder Beginner Contest 254 By xiaruize A - Last Two Digits 签到题: 12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455// Problem: A - Last Two Digits// Contest: AtCoder - AtCoder Beginner Contest 254// URL: https://atcoder.jp/contests/abc254/tasks/abc254_a// Memory Limit: 1024 MB// Time Limit: 2000 ms//// Powered by CP Editor (https://cpeditor.org)/* Name: Author: xiaruize Date:*/#include <bits/stdc++.h>using namespace std;#define ...
作者信息
Announcement
Hi! This is xiaruize's Blog