python

#!/usr/bin/envpython#encoding=utf-8#Date:2016-08-25#Author:Eric.zhangtj@homecredit.cn#Purpose:JustforfunTableLenth=int(raw_input("InputtheMaxlinesyouwant:\n"))foriinrange(1,TableLenth+1):forjinrange(1,i+1):result=i*jprint"%s*%s=%s\t"%(i,j,result),print"\n"


shell

#!/bin/bash#encoding=utf-8#Date:2016-08-25#Author:Eric.zhangtj@homecredit.cn#Purpose:Justforfunread-p"InputtheMaxlinesyouwant:"TableLenthforiin$(seq1$TableLenth)doforjin$(seq1$i)doresult=$[$i*$j]echo-n-e"$i+$j=$result\t"doneecho-e"\n"done


C




java


classMultiTable{publicstaticvoidmain(String[]args){inti,j;for(i=1;i<=9;i++){for(j=1;j<=i;j++){System.out.print(i+"*"+j+"="+i*j+"\t");}System.out.print("\n");}}}