当前位置:网站首页>勾股数元组 od js
勾股数元组 od js
2022-07-31 01:18:00 【大鸡腿最好吃】


let a=readline()
let b=readline()
let res='NA',f=false
function hz(x,y){
let min=Math.min(x,y)
for(let p=2;p<min/2;p++){
if(x%p==0&&y%p==0)return false
}
return true
}
for(let i=a;i<b-2;i++){
for(let j=i+1;j<b-1;j++){
for(let k=j+1;k<b;k++){
if(hz(i,j)&&hz(i,k)&&hz(j,k)){
if(i*i+j*j==k*k){
f=true
console.log(i+' '+j+' '+k)
}
}
}
}
}
if(!f)console.log(res)
边栏推荐
- typescript10-commonly used basic types
- 倍增、DFS序
- 网站频繁出现mysql等数据库连接失败等信息解决办法
- 【genius_platform软件平台开发】第七十四讲:window环境下的静态库和动态库的一些使用方法(VC环境)
- typescript12 - union types
- TypeScript在使用中出现的问题记录
- 系统设计.短链系统设计
- 手把手教你配置Jenkins自动化邮件通知
- DOM系列之动画函数封装
- "Actual Combat" based on part-of-speech extraction in the field of e-commerce and its decision tree model modeling
猜你喜欢

Mysql: Invalid default value for TIMESTAMP

1782. Count the number of point pairs Double pointer

小黑leetcode之旅:117. 填充每个节点的下一个右侧节点指针 II

剑指offer17---打印从1到最大的n位数

【ABAP】MFBF过账到质量检验库存类型Demo

tkinter模块高级操作(二)—— 界面切换效果、立体阴影字效果及gif动图的实现

Typescript14 - (type) of the specified parameters and return values alone

Centos 7.9 install PostgreSQL14.4 steps

解析云原生消息流系统 Apache Pulsar 能力及场景

typescript15- (specify both parameter and return value types)
随机推荐
MySql data recovery method personal summary
typescript13-类型别名
typescript10-commonly used basic types
Mysql: Invalid default value for TIMESTAMP
射频器件的基本参数2
使用docker安装mysql
ECCV 2022丨轻量级模型架构火了,力压苹果MobileViT(附代码和论文下载)
Problem record in the use of TypeScript
图像处理工具设计
Know what DTU is 4GDTU equipment
九州云入选“可信云最新评估体系及2022年通过评估企业名单”
Word 表格跨页,仍然显示标题
TiDB之rawkv升级之路v5.0.4--&gt;v6.1.0
typescript11-数据类型
Preparations for web vulnerabilities
ShardingSphere之垂直分库分表实战(五)
24. Please talk about the advantages and disadvantages of the singleton pattern, precautions, usage scenarios
ROS Action通信
分布式.幂等性
87. 把字符串转换成整数