当前位置:网站首页>Make a three digit number of all daffodils "recommended collection"
Make a three digit number of all daffodils "recommended collection"
2022-07-01 22:11:00 【Full stack programmer webmaster】
Hello everyone , I meet you again , I'm your friend, Quan Jun .
/**
* subject : Print out all " Narcissistic number ", So-called " Narcissistic number " A three digit number ,
* The sum of its cubes is equal to the number itself . for example :153 It's a " daffodils
* Count ", because 153=1 The third power of +5 The third power of +3 The third power of
*/
public class Narcissistic number {
public static void main(String[] args) {
for (int i = 100; i < 1000; i++) {
int first = i/100;
int secode= i/10%10;
int thrid = i%10;
if (first*first*first+secode*secode*secode+thrid*thrid*thrid == i) {
System.out.println(i+" It's Narcissus ");
}
}
}
}Publisher : Full stack programmer stack length , Reprint please indicate the source :https://javaforall.cn/147187.html Link to the original text :https://javaforall.cn
边栏推荐
- Icml2022 | interventional contrastive learning based on meta semantic regularization
- 浏览器tab页之间的通信
- 函数基本学习之一
- pytest合集(2)— pytest运行方式
- MySQL数据库驱动(JDBC Driver)jar包下载
- 杰理之蓝牙耳机品控和生产技巧【篇】
- 杰理之烧录上层版物料需要【篇】
- Go - exe corresponding to related dependency
- 股票手机开户哪个app好,安全性较高的
- [STM32] stm32cubemx tutorial II - basic use (new projects light up LED lights)
猜你喜欢

工控设备安全加密的意义和措施

东哥套现,大佬隐退?

基于K-means的用户画像聚类模型

手动实现function isInstanceOf(child,Parent)

ICML2022 | 基于元语义正则化的介入性对比学习

Talking from mlperf: how to lead the next wave of AI accelerator

List announced | outstanding intellectual property service team in China in 2021

Significance and measures of security encryption of industrial control equipment

Do you want to make up for the suspended examination in the first half of the year? Including ten examinations for supervision engineers, architects, etc

业务可视化-让你的流程图'Run'起来
随机推荐
信标委云原生专题组组长,任重道远!
从MLPerf谈起:如何引领AI加速器的下一波浪潮
【Opencv450】HOG+SVM 与Hog+cascade进行行人检测
能升职加薪?PMP证书含金量浅析
String类型转换BigDecimal、Date类型
Test cancellation 1
Talking from mlperf: how to lead the next wave of AI accelerator
MySQL清空表数据
最近公共祖先离线做法(tarjan)
十三届蓝桥杯B组国赛
杰理之烧录上层版物料需要【篇】
UVM教程
函数基本学习之一
Icml2022 | interventional contrastive learning based on meta semantic regularization
CNN卷积神经网络原理讲解+图片识别应用(附源码)[通俗易懂]
辅音和声母的区别?(声母与辅音的区别)
K-means based user portrait clustering model
Yan Rong looks at how to formulate a multi cloud strategy in the era of hybrid cloud
从20s优化到500ms,我用了这三招
[STM32] stm32cubemx tutorial II - basic use (new projects light up LED lights)