发表于: 2017-07-16 22:57:29
1 1166
今天完成的事情:
完成后台公司的更新和新增接口
听付老师讲课(插入排序和冒泡排序)
public class Charu {
public static void main(String[] args)
{
int[] a={1,2,3,10,6,8,18,15};
for(int x=0;x<a.length-1;x++)
{
for(int i=x;i>=0;i--)
{
if(a[i]>a[i+1])
{
int tem;
tem=a[i];
a[i]=a[i+1];
a[i+1]=tem;
}
}
}
for(int x=0;x<a.length;x++)
{
System.out.print(a[x]+" ");
}
}
}
上为插入排序下为冒泡排序
class Maopao {
public static void main(String[] args)
{
int[] a={1,2,3,10,9,2,22,15,18};
for(int i=0;i<a.length-1;i++)
{
for(int x=0;x<a.length-1-i;x++)
{
if(a[x]>a[x+1])
{
int tem;
tem=a[x];
a[x]=a[x+1];
a[x+1]=tem;
}
}
}
for(int x=0;x<a.length;x++)
{
System.out.print(a[x]+" ");
}
}
}
明天计划的事情:
开始写完成后台公司接口的调试开始写职位接口
遇到的问题:
开始接口后发现很多自己只能说了解的知识要实现 还是有一定的难度
收获:
加油加油加油!!!!
评论