A. Colorful Stones (Simplified Edition)

time limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputThere is a sequence of colorful stones. The color of each stone is one of red, green, or blue. You are given a string s. The i-th (1-based)

A. Way Too Long Words

time limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputSometimes some words like "localization" or "internationalization" are so long that writing them many times in one text is quite tiresome.Let's

1680 Catalan數

描述塔蘭數是組合數學中一個常出現在各種計數問題中出現的數列。由以比利時的數學家歐仁·查理·卡塔蘭(1814–1894)命名。卡塔蘭數滿足以下遞推關係它的通項公式為前幾項為 : 1, 2, 5, 14, 42, 132, 429, 1430, 4862, 16796, 58786, 208012, 742900, 2674440, 9694845, 35357670, 129644790, 477638700,

A. Parallelepiped

time limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputYou've got a rectangular parallelepiped with integer edge lengths. You know the areas of its three faces that have a common vertex. Your task is to

A. Theatre Square

time limit per test2 secondsmemory limit per test64 megabytesinputstandard inputoutputstandard outputTheatre Square in the capital city of Berland has a rectangular shape with the size n × m meters. On the occasion of the city's anniversary, a

A. Little Elephant and Function

time limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputThe Little Elephant enjoys recursive functions.This time he enjoys the sorting function. Let a is a permutation of an integers from 1 to n,

B. Drinks

time limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputLittle Vasya loves orange juice very much. That's why any food and drink in his kitchen necessarily contains orange juice. There are n drinks in

B. Taxi

time limit per test3 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputAfter the lessons n groups of schoolchildren went outside and decided to visit Polycarpus to celebrate his birthday. We know that the i-th group

A. Bicycle Chain

time limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputVasya's bicycle chain drive consists of two parts: n stars are attached to the pedal axle, m stars are attached to the rear wheel axle. The chain

A. Word

time limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputVasya is very upset that many people on the Net mix uppercase and lowercase letters in one word. That's why he decided to invent an extension for

A. Cifera

time limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputWhen Petya went to school, he got interested in large numbers and what they were called in ancient times. For instance, he learned that the Russian

A. Toy Army

time limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputThe hero of our story, Valera, and his best friend Arcady are still in school, and therefore they spend all the free time playing turn-based

A. Watermelon

time limit per test1 secondmemory limit per test64 megabytesinputstandard inputoutputstandard outputOne hot summer day Pete and his friend Billy decided to buy a watermelon. They chose the biggest and the ripest one, in their opinion. After that the

A. Greg’s Workout

time limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputGreg is a beginner bodybuilder. Today the gym coach gave him the training plan. All it had was n integers a1, a2, ..., an. These numbers mean that

1682 GG取數

GG取數時間限制:1000 ms  |  記憶體限制:65535 KB描述任給出正整數n和k(1<=n<=1,000,000 , 0<=k<=n),取數規則如下:例如n=16,k=4第一次取數 1 取數後的餘數為16-1=15第二次取數 2 取數後的餘數為15-2=13第三次取數 4 取數後的餘數為13-4=9第四次取數 8 取數後的餘數為 9-8=1當第五次取數時,因為餘數是1,不夠取,此時作如下處理餘數1+k=5,再從1開始取第五次取數 1

A. Dima and Friends

time limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputDima and his friends have been playing hide and seek at Dima's place all night. As a result, Dima's place got messy. In the morning they decided

A. Next Round

time limit per test3 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard output"Contestant who earns a score equal to or greater than the k-th place finisher's score will advance to the next round, as long as the contestant

A. Buggy Sorting

time limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputLittle boy Valera studies an algorithm of sorting an integer array. After studying the theory, he went on to the practical tasks. As a result, he

A. Chips

time limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputThere are n walruses sitting in a circle. All of them are numbered in the clockwise order: the walrus number 2 sits to the left of the walrus

B. Squares

time limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputVasya has found a piece of paper with a coordinate system written on it. There are n distinct squares drawn in this coordinate system. Let's number

總頁數: 61357 1 .... 19717 19718 19719 19720 19721 .... 61357 Go to: 前往

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.