A. Eleven
time limit per test :

1 second

memory limit per test: 

256 megabytes

input: 

standard input

output: 

standard output

Eleven wants to choose a new name for herself. As a bunch of geeks, her friends suggested an algorithm to choose a name for her. Eleven wants her name to have exactly n characters.

Her friend suggested that her name should only consist of uppercase and lowercase letters 'O'. More precisely, they suggested that the i-th letter of her name should be 'O' (uppercase) if i is a member of Fibonacci sequence, and 'o' (lowercase) otherwise. The letters in the name are numbered from 1 to n. Fibonacci sequence is the sequence f where

  • f1 = 1,
  • f2 = 1,
  • fn = fn - 2 + fn - 1 (n > 2).

As her friends are too young to know what Fibonacci sequence is, they asked you to help Eleven determine her new name.

Input

The first and only line of input contains an integer n (1 ≤ n ≤ 1000).

Output

Print Eleven's new name on the first and only line of output.

Examples
input
8
output
OOOoOooO
input
15
output
OOOoOooOooooOoo
 #include<bits/stdc++.h>
using namespace std; int FB[]; void init()
{
int t;
for(int i = ; i < ; i++)
FB[i] = ;
FB[] = FB[] = ;
for(int i = ; i < ;i++)
{ FB[i] = FB[i-] + FB[i-];
}
} int main()
{
init();
int n; while(~scanf("%d",&n))
{
int temp = ;
for(int i = ; i <= n; i++)
{
if(i == FB[temp])
{
printf("O");
temp++;
}
else
{
printf("o");
}
}
printf("\n");
}
return ;
}

Eleven的更多相关文章

  1. Eleven puzzle_hdu_3095(双向广搜).java

    Eleven puzzle Time Limit: 20000/5000 MS (Java/Others)    Memory Limit: 32768/32768 K (Java/Others) T ...

  2. Codeforces Round #459 (Div. 2)-A. Eleven

    A. Eleven time limit per test1 second memory limit per test256 megabytes Problem Description Eleven ...

  3. B - Eleven

    Problem description Eleven wants to choose a new name for herself. As a bunch of geeks, her friends ...

  4. python爬虫-携程-eleven参数

    携程-eleven分析 一.eleven的位置 通过对旁边栈的分析,它是在另一个js文件中调用的.那个js文件是一个自调用的函数,所以我们可以直接copy下来,用浏览器执行看看 执行运行是会报错的,u ...

  5. UVA 12672 Eleven(DP)

    12672 - Eleven Time limit: 5.000 seconds In this problem, we refer to the digits of a positive integ ...

  6. TIJ——Chapter Eleven:Holding Your Objects

    Java Provides a number of ways to hold objects: An array associates numerical indexes to objects. It ...

  7. Eleven scrum meeting 2015/11/5

    今日工作情况 小组成员 今日完成的工作 明日待做任务 唐彬 选课和退课模块 测试 赖彦谕 病情较重,请假 病情较重,请假 金哉仁 设计app logo 测试 闫昊 调整课程简介的展示效果 整合各个模块 ...

  8. 100-days: eleven

    Title: Facebook's live streaming(网络直播) is criticized(批评) after mosque(清真寺) shooting(枪击). live adj.现场 ...

  9. UVALive 6529 Eleven 区间dp

    题目链接:option=com_onlinejudge&Itemid=8&page=show_problem&problem=4540">点击打开链接 题意: ...

随机推荐

  1. 解析 Javascript - this

    在函数中 this 到底取何值,是在函数真正被调用执行的时候确定下来的,函数定义的时候确定不了.  因为 this 的取值是执行上下文环境的一部分,每次调用函数,都会产生一个新的执行上下文环境.当你在 ...

  2. 清除session信息

    session.removeAttribute("sessionname")是清除SESSION里的某个属性.     session.invalidate()是让SESSION失 ...

  3. Javascript之Event Loop

    先看段代码: console.log(1); setTimeout(function () { console.log(2); new Promise(function (resolve, rejec ...

  4. 远程连接服务器jupyter notebook、浏览器以及深度学习可视化方法

    h1 { counter-reset: h2counter; } h2 { counter-reset: h3counter; } h3 { counter-reset: h4counter; } h ...

  5. java8接口定义增强

    java1.7之前,接口中只允许有全局常量和抽象方法,而1.8之后允许在接口中扩充default修饰的普通方法和static修饰的静态方法 其目的是在修改接口中方法的时候,子类就不必去一一修改 pac ...

  6. Linux服务器断电导致挂载及xfs文件损坏的修复方法

    系统文件损坏后进入紧急修复模式,无法进行维护工作 welcome to emergency mode!after logging in ,type "journalctl -xb" ...

  7. [python]使用django快速生成自己的博客小站,含详细部署方法

    前言 人生苦短,我用python 这是之前经常听到的一句笑谈.因为新公司很多业务是用的python语言,所以这几天也一直在学习python的一些东西. 作为一个之前一直java后端的开发人员,对比ja ...

  8. [Codeforces 946D]Timetable

    Description 题库链接 给你一个 \(N\times M\) 的 \(01\) 矩阵,你可以从中将一些 \(1\) 变为 \(0\) ,最多 \(K\) 次.使操作之后使得每行最远的 \(1 ...

  9. [HNOI 2014]道路堵塞

    Description A国有N座城市,依次标为1到N.同时,在这N座城市间有M条单向道路,每条道路的长度是一个正整数.现在,A国 交通部指定了一条从城市1到城市N的路径,并且保证这条路径的长度是所有 ...

  10. [SCOI2010]幸运数字

    题目描述 在中国,很多人都把6和8视为是幸运数字!lxhgww也这样认为,于是他定义自己的“幸运号码”是十进制表示中只包含数字6和8的那些号码,比如68,666,888都是“幸运号码”!但是这种“幸运 ...