当前位置:网站首页>打印星型图「建议收藏」
打印星型图「建议收藏」
2022-08-09 15:36:00 【全栈程序员站长】
大家好,又见面了,我是你们的朋友全栈君。
package 算法;
public class 打印星型图 { public static void main(String[] args) { for(int i=1;i<4;i++){ for(int j=0;j<(i-1)*2+1;j++){ System.out.print(“*”); } System.out.println(); } for(int i=3;i>0;i–){ for(int j=(i-1)*2+1;j>0;j–){ System.out.print(“*”); } System.out.println(); } }
}
发布者:全栈程序员栈长,转载请注明出处:https://javaforall.cn/106029.html原文链接:https://javaforall.cn
边栏推荐
- resubmit 渐进式防重复提交框架简介
- 开始记录自己的学习过程和目标
- [1413. Stepwise summation to get the minimum value of positive numbers]
- 2022年深圳杯数学建模A题代码思路-- 破除“尖叫效应”与“回声室效应”,走出“信息茧房”
- Chapter 3: Use of GEE Data (3.4-3.11)
- 网络——涉及的相关协议和设备汇总
- 六.数组越界问题引出对栈区内存的探索
- 小心使用C语言realloc()函数!!!
- 2022年8月9日:用C#生成.NET应用程序--使用 Visual Studio Code 调试器,以交互方式调试 .NET 应用(不会,失败)
- 网络——流量控制&可靠传输&滑动窗口
猜你喜欢
Anatomy of Storage Size, Value Range, and Output Format of Basic Data Types in C Language
微服务框架笔记(1)
uniapp 项目搭建
Heap series_0x0A: 3 methods to solve the heap overflow problem at once
Super hot summer air conditioner
一个程序员的水平能差到什么程度?
IDEA中操作数据库 以MySQL为例,可以放弃Navicat了
网络——路由器
The web project accesses static resources inside the jar
August 9, 2022: Build .NET apps in C# -- use the Visual Studio Code debugger to interactively debug .NET apps (won't, fail)
随机推荐
【燃】是时候展现真正的实力了!一文看懂2022华为开发者大赛技术亮点
网络——介质访问控制
Knowledge Bits - How to Write a Project Summary
Three ways to find prime numbers
character rhombus code
领先实践|全球最大红酒App如何用设计冲刺创新vivino模式
网络——数字数据编码
Access Characteristics of Constructor under Inheritance Relationship
Heap series_0x0A: 3 methods to solve the heap overflow problem at once
2022年8月9日:用C#生成.NET应用程序--使用 Visual Studio Code 调试器,以交互方式调试 .NET 应用(不会,失败)
Two ways to find the factorial of n
网络——彻底搞懂数据时延的相关计算
2. Creating Interactive Maps
Anatomy of Storage Size, Value Range, and Output Format of Basic Data Types in C Language
如何判断闰年
Heap series_0x09: Example of heap corruption (illegal access + uninitialized + heap handle mismatch)
巧用Prometheus来扩展kubernetes调度器
图像几何校正
良匠-手把手教你写NFT抢购软(二)
开源星「001 号」落地 FlyFish,欢迎登陆赢神秘大礼包!