cf462 A Compatible Pair

安装mysql出现no compatible servers were found 问题描述 今天在安装数据库的过程中,遇到错误提示: No compatible servers were found,You'll need to cancel this wizard and install one! 如下图所示: 精通于数据库的安装与卸载的我,竟然也有“湿鞋”的一天,懵逼一段时间之后,首先想到的就是以前的注册表信息没有删干净,嗯,一定是这样,果断去控制面板卸载my... 阅读详情

找多少个圈,我记得小学找规律的题目

B. A Prosperous Lot
time limit per test
1 second
memory limit per test
256 megabytes
input
standard input
output
standard output

Apart from Nian, there is a daemon named Sui, which terrifies children and causes them to become sick. Parents give their children money wrapped in red packets and put them under the pillow, so that when Sui tries to approach them, it will be driven away by the fairies inside.

Big Banban is hesitating over the amount of money to give out. He considers loops to be lucky since it symbolizes unity and harmony.

He would like to find a positive integer n not greater than 1018, such that there are exactly k loops in the decimal representation of n, or determine that such n does not exist.

A loop is a planar area enclosed by lines in the digits' decimal representation written in Arabic numerals. For example, there is one loop in digit 4, two loops in 8 and no loops in 5. Refer to the figure below for all exact forms.

Input

The first and only line contains an integer k (1 ≤ k ≤ 106) — the desired number of loops.

Output

Output an integer — if no such n exists, output -1; otherwise output any such n. In the latter case, your output should be a positive decimal integer not exceeding 1018.

Examples
Input
2
Output
462
Input
6
Output
8080

#include<iostream>
#include<algorithm>
using namespace std;
typedef long long ll;
#define f(i,l,r) for(int i=l;i<=r;i++)
#define g(i,l,r) for(int i=l;i>=r;i--)
 //888888888888888888 18* 2  === 36

int main()
{
	int n;
	cin>>n;
	if(n>36)cout<<-1<<endl;
	else
	{
		if(n%2==1) cout<<1;
		f(i,1,n/2) cout<<8;
		cout<<endl;
	}
	return 0;
}

未来的我一定会感谢现在正在成长的我

【信息科学与工程学】【通信工程】第七十六篇 网络解决方案设计03 继续围绕智算中心相关的组网设计、光路设计、波分设计、OTN设备、交换机设备、组网拓扑、网络操作系统、业务区/管理区/存储区、光设计、租户设计、电磁设计、队列设计、QoS设计、调度设计、组合设计等领域。: 若Tpxe​=2min,Tos_install​=5min,Tagent​=0.5min,Tconfig​=0.5min,则Tready​=8min。: 若N=2000,Ms​=2,Nstorage​=128,Mss​=2,则Nip​=2000×2+128×2=4256,需要/20子网。 阅读详情

相关推荐

GD32F450以太网(2-2): PHY芯片IP101GR介绍

IP101是台湾省九阳电子公司生产制造的,符合IEEE 802.3/802.3u标准单端口快速以太网收发器100Mbps和10Mbps操作,它支持自动MDI/MDIX功能,简化网络安装和减少系统维护成本。支持Auto MDI/MDIX已内置4个49.9欧的精密电阻支持中断功能支持 MII/RMII 接口超低功耗

Zhichao_Zhang的博客 1万+

934B A Prosperous Lot

B. A Prosperous Lot time limit per test1 second memory limit per test256 megabytes inputstandard input outputstandard output Apart from Nian, there is a daemon named Sui, which terrifies children

memory_qianxiao的博客 701

cadence capture CIS 之使用access创建数据库(.mdb)

cadence capture CIS 之使用access创建数据库(.mdb)准备工作新建数据库 准备工作 1、一台电脑; 2、安装 Microsoft access database; 新建数据库 打开你准备创建数据库的位置,右键单击——》新建——》 Microsoft access database(注意:文件格式要选*.mdb) 打开数据库文件,创建——》表; 对数据表进行编辑,编辑表头、编辑表的内容、增加表的数量; 编辑表头:选中要编辑的表——》表设计 编辑内容:类似于excel添

weixin_42256550的博客 3145

934B. A Prosperous Lot

Apart from Nian, there is a daemon named Sui, which terrifies children and causes them to become sick. Parents give their children money wrapped in red packets and put them under the pillow, so that w...

码农的一亩三分地 604

别再只做游戏了!用虚幻引擎5(UE5)给你的工厂车间做个数字双胞胎(附数据对接教程)

本文详细介绍了如何利用虚幻引擎5(UE5)构建工业数字孪生系统,实现工厂车间的智能可视化。通过UE5的高质量渲染和实时数据处理能力,结合OPC UA和MQTT协议,打造高效的数据对接方案,提升异常识别和设备管理效率。文章还分享了模型优化、可视化设计及典型工业场景的实战案例,助力企业迈向工业4.0。

weixin_33738555的博客 206

OSError We couldn‘t connect to https://huggingface.co to load file, couldn‘t find it chatglm3-6b解决方案

本文主要介绍了OSError: We couldn’t connect to https://huggingface.co to load this file, couldn’t find it in the cached files and it looks like THUDM/chatglm3-6b is not the path to a directory containing a file named config.json.解决方案,希望能对学习python的同学们有所帮助。

weixin_43178406的博客 5万+

Codeforces Round #462 (Div. 2) B. A Prosperous Lot

B. A Prosperous Lottime limit per test1 secondmemory limit per test256 megabytesinputstandard inputoutputstandard outputApart from Nian, there is a daemon named Sui, which terrifies children and cause...

aaakirito的博客 372

R语言生存分析之竞争风险模型

R语言生存分析之竞争风险模型 竞争风险模型(Competing Risk Model)是一种处理多种潜在结局生存数据的分析方法,早在1999年Fine和Gray就提出了部分分布的半参数比例风险模型,通常使用的终点指标是累积发生率函数(cumulative incidence function,CIF)。 研究中结局事件可能有多个,某些结局将阻止感兴趣事件的出现或影响其发生的概率,各结局事件形成“竞争”关系,互为竞争风险事件。 竞争风险模型( Competing Risk Model ) : 指

data+scenario+science+insight 5246

Codeforces 934B A Prosperous Lot

B. A Prosperous LotApart from Nian, there is a daemon named Sui, which terrifies children and causes them to become sick. Parents give their children money wrapped in red packets and put them under th...

s540239976的博客 413

SAP 标准 CDS View 到底能不能用 CDS Extension View 扩展,我们在项目里应该这样判断

文章摘要:判断SAP标准CDS视图(如A_PRODUCT)能否扩展字段,不能仅凭命名或@Metadata.allowExtensions判断,需检查DDL源码中的@AbapCatalog.viewEnhancementCategory值。#PROJECTION_LIST允许扩展字段,#NONE则禁止。聚合视图需额外包含#GROUP_BY,UNION视图需#UNION。CDS View Extension用于新增字段,Metadata Extension仅用于添加注解。在ABAP Cloud环境中还需检查AP

2007 年 ~ 2025 年,深耕 SAP 技术 18 年 98

YOLOv11改进策略【注意力机制篇】| SE、CBAM、ECA、CA、Swin Transformer等注意力机制全面解析与应用

本文详细介绍了五种主流的注意力机制及其在YOLOv11中的应用。通过合理的模块选择和位置部署,注意力机制能够显著提升目标检测性能。

QQ_778132974的博客 873

CodeForces 934 B.A Prosperous Lot(思维)

题意 输入一个n,输出一个有n个环的数,这个数在0-1e18之间。 题解 只要输出4或8就行了,要注意数的范围,超过就输出-1。 #include &lt;bits/stdc++.h&gt; using namespace std; int main(){ int n; while(cin&gt;&gt;n){ if(n == 0 || n &gt; 2*18){ cou...

yanhu6955的博客 252

基于R语言的PLS算法实现解读

我们使用"pls"包来执行PLS回归,并提供了相应的源代码。在本文中,我们将详细解读基于R语言的PLS算法的实现过程,并提供相应的源代码。PLS算法的实现可以借助R语言中的"pls"包。该包提供了丰富的函数和工具,用于执行PLS回归、PLS-DA(PLS-Discriminant Analysis)和其他相关任务。除了执行PLS回归,"pls"包还提供了其他功能,例如PLS-DA(用于分类问题)和PLS变量选择等。上述代码将基于输入的X值,使用训练好的PLS模型进行预测,并返回预测结果。

TechWhizKid的博客 1043

Codeforces Round #462 (Div. 2) B-A Prosperous Lot

B. A Prosperous Lottime limit per test1 secondmemory limit per test256 megabytesinputstandard inputoutputstandard outputApart from Nian, there is a daemon named Sui, which terrifies children and cause...

执念 290

pscad IEEE标准系统搭建说明

pscad IEEE标准系统搭建说明,包含典型的IEEE 9节点、14节点、30节点、39节点和118节点系统。内含标准测试系统的原始数据和潮流结果。

Outlook Express 6 (OE6) for Win7/Win8/Win10

英文版 Outlook Express6.0, 兼容Win7/Win10/WinXP,解压就可用。

安装mysql时,出现No compatible servers were found.You'll need to cancel this wizard and install one

安装Visual C++就可以完美解决了! 这是下载地址:https://www.microsoft.com/zh-cn/download/confirmation.aspx?id=40784 注意:不管系统是32位或者64位的,一定要安装x86,具体我也不清楚为啥! ...

qq_33180812的博客 7269

华为的C语言编程规范.pdf

华为技术有限公司内部技术规范。本规范制定了编写C语言程序的基本原则、规则和建议。从代码的清晰、简洁、可测试、安全、程序效率、可移植各个方面对C语言编程作出了具体指导。

A Prosperous Lot CodeForces - 934B

Apart from Nian, there is a daemon named Sui, which terrifies children and causes them to become sick. Parents give their children money wrapped in red packets and put them under the pillow, so that w...

tomjobs的博客 475

复分析 阿尔福斯(Ahlfors) 第三版答案 英文

答案分为十章,有部分习题没有答案,全英文复分析阿尔福斯(Ahlfors) 第三版答案

[2020-3-6]BNUZ套题比赛div3解题报告

[2020-3-6]BNUZ套题比赛div3解题报告 2020/3/8 非常荣幸,本周蝉联了训练赛的第一名×2。不过,两个小时只憋出来两题,有点寒酸。(排名如下图) 话不多说,上题 第一题 Pizza, Pizza, Pizza!!! Katie, Kuro and Shiro are best friends. They have known each other since kinderga...

BNUZ_Clearlove的博客 377

Codeforces Round #462 (Div. 2) B - A Prosperous Lot

构造#include&lt;iostream&gt; #include&lt;algorithm&gt; #include&lt;iomanip&gt; #include&lt;cstdio&gt; #include&lt;cstdlib&gt; #include&lt;cstring&gt; #include&lt;string&gt; #include&lt;cmath&gt;

床前明月光 271

No compatible servers were found. You'll need to cancel this wizard and install one.

MySql安装失败 No compatible servers were found. You’ll need to cancel this wizard and install one. 参照:此文完美解决

展翅雄鹰的博客 3780

MySQL安装出现的问题

出现如下错误提示:No compatible servers were found.You'll need to cancel this wizard and install one.解决方法:安装最新版本的Visual C++,即可解决。安装过程可参考如下链接:点击打开链接...

weijiahui_的博客 4256

安装MySQL时出现no compatible servers were found的解决方法

正如图中所说,原因是缺少服务器,其实就是没有安装MySQL server。 我建议进入控制面板的卸载程序中 把刚刚安装的跟MySQL相关的软件都删除干净。然后重新打开MySQL的安装程序,重新安装。 1、这里选择自定义安装 2、我只添加了三个选项 3、关键是这一步,你需要点击图中的Execute,然后根据提示安装所需要的C++组件 这时出来如图提示,一定要选择repair或者修复!不...

qq_44766592的博客 1万+

CodeForces - 934B. A Prosperous Lot

B. A Prosperous Lot time limit per test1 second memory limit per test256 megabytes inputstandard input outputstandard output Apart from Nian, there is a daemon named Sui, which terrifies children...

风之谷里腌三腊菜 286

MySQL安装问题no compatible servers were found.You’ll need to cancel this wizard and install one

no compatible servers were found.You’ll need to cancel this wizard and install one 问题:当win10安装MySQL时遇到以下情况 安装失败的原因是需要升级一个插件,Visual C++ 2013 and Visual C Redistributable Package 解决方法: 1.去 https://www.microsoft.com/zh-cn/download/details.aspx?id=40784 下载安装包

qq_38916614的博客 8915

安装mysql数据库出现no compatible servers were found 解决办法

https://www.sohu.com/a/227127720_100098990看了他的文章成功了,记录一下,如果以后再安装还用的到.

zj1442490435的博客 2万+
上一篇: cf462 A Compatible Pair
下一篇: cf462 A Twisty Movement
PragIncor
博客等级 码龄9年 1粉丝 59原创
评论
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

个

红包个数最小为10个

元

红包金额最低5元

当前余额3.43元 前往充值 >
需支付:10.00元
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付元
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值