Fernando won a compass for his birthday, and now his favorite hobby is drawing stars: first, he marks N points on a circumference, dividing it into N equal arcs; then, he connects each point to the k-th next point, until returning to the first point. D…
F: Star Time Limit: 1 s Memory Limit: 128 MB Submit My Status Problem Description 31世纪,人类世界的科技已经发展到了空前的高度,星际移民,星际旅游早已经不再是问题.人类已经掌握了开发星系的能力.但是,无论发展到何种地步,资源一直是人们关注的重点.一种新的能源被人类掌握,通过它可以搭建虫洞,实现超光年传输.发展武器.但是虽然这种物质在宇宙海量的存在着,但它对于宇宙的稳定是至关重要的,若过量消耗这种物质,对…
HDU 4891 The Great Pan 注册标题 他怎么说,你怎么样 需要注意的是乘法时,它会爆炸int 代码: #include<iostream> #include<cstdio> #include<cstring> #include<algorithm> using namespace std; typedef long long LL; int n; char s[2000000]; int flag1, flag2, sp, ansfla…
Profunctor class Profunctor p where dimap :: (a -> b) -> (c -> d) -> p b c -> p a d dimap f g = lmap f . rmap g lmap :: (a -> b) -> p b c -> p a c lmap f = dimap f id rmap :: (b -> c) -> p a b -> p a c rmap = dimap id Prof…