输出乘法顺序表
来源:互联网 发布:php程序员是什么意思 编辑:程序博客网 时间:2024/06/01 07:50
请编写一个程序,输出以下乘法表
3*3=9
3*4=12 4*4=16
3*5=15 4*5=20 5*5=25
3*6=18 4*6=24 5*6=30 6*6=36
3*7=21 4*7=28 5*7=35 6*7=42 7*7=49
import java.util.Scanner;public class show_multiplication_table {public static void main(String[] args){int s,e;Scanner reader = new Scanner(System.in);System.out.println("请输入乘法表的起点数字:");s=reader.nextInt();System.out.println("请输入乘法表的终点数字:");e=reader.nextInt();print_table print = new print_table();print.print(s, e);}}public class print_table {int i,j;void print(int start,int end){for(i = start; i<=end; i++){for(j = start; j<=i; j++){System.out.printf(j+"*"+i+"="+i*j+" ");}System.out.println();//输出换行符,}}}
阅读全文
0 0
- 输出乘法顺序表
- 输出乘法口诀表
- 输出乘法口诀表
- 输出乘法口诀表
- 输出乘法口诀表
- C++ 输出乘法表
- 输出乘法口诀表
- 输出乘法口诀表
- 输出乘法口诀表
- 输出乘法口诀表
- 输出乘法口诀表
- 输出乘法口诀表
- 输出乘法口诀表
- 输出乘法口诀表
- 输出乘法口诀表
- 输出乘法口诀表
- 输出乘法口诀表
- 输出乘法口诀表
- 11 cookie&&session的学习笔记
- Linux下查看文件精确到秒的修改时间
- poj 3468 线段树
- poj1094 Sorting It All Out
- js中for循环的作用域;函数调用的理解;数组对象的理解;
- 输出乘法顺序表
- 求C_18^13的值
- hdu 6006 Engineer Assignment(状压DP)
- spring注解
- docker本机启动多台容器导致出现后续容器启动失败
- 留言板功能
- python 修饰器
- 没有对象的指针是野指针【用C语言做生日贺卡】
- 智能指针