自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+

  • 博客(42)
  • 收藏
  • 关注

转载 override与overload的区别

1转载于:https://www.cnblogs.com/taoxiuxia/p/4554842.html

2015-06-05 15:57:00 148

转载 tomcat添加用户

tomcat下添加用户和密码:conf下tomcat-user.xml添加<role rolenames="manager-gui"/> <user username="abc" password="aaaaa" roles="manager-gui"/> 这样就增加了一个用户,用户名abc,密码是aaaaa,角色是manager-gu...

2015-06-05 11:39:00 169

转载 Ubuntu配置Eclipse

转载自如何在Ubuntu 14.04中安装最新版Eclipse想必很多开发人员都知道,Ubuntu 软件源中提供的并不是最新版本的 Eclipse,本教程就教大家如何在 Ubuntu 14.04 中快速安装 Eclipse 官方发布的最新版本。到目前为止,Eclipse 的官方最新版本为 Eclipse Kepler (4.3.2),我们可以使用如下步骤在 Ubuntu 14.0...

2015-05-15 18:55:00 173

转载 Ubuntu配置JDK

转载自Ubuntu 12.10 安装 jdk-7u10-linux-x64.tar.gz1.将jdk-8u45-linux-i586.tar.gz.tar.gz拷贝到/usr/lib/jdk/目录下面,这里如果没有jdk文件夹,则创建该文件夹,命令: sudo mkdir jdk //创建文件夹jdk sudo cp -r ~/download/jdk-8u4...

2015-05-15 01:44:00 140

转载 算法学习

我的算法学习之路-lucida转载于:https://www.cnblogs.com/taoxiuxia/p/4458447.html

2015-04-26 21:37:00 130

转载 Java:Constructors and polymorphism

As usual, constructors are different from other kinds of methods. This is also true when polymorphism is involved. Even though constructors are not polymorphic(they're actually static methods, bu...

2015-04-25 20:51:00 162

转载 Java:The final Keyword

看不懂 1 import java.util.*; 2 3 class Value { 4 int i; 5 6 public Value(int i) { 7 this.i = i; 8 } 9 }10 11 public class FinalData {12 13 priv...

2015-04-23 20:57:00 143

转载 Java:thinking in java p241 exercise1

Create a simple class. Inside a second class, define a reference to an object ofthe first class. Use lazy initialization to instantiate this object. 1 import static org.greggordon.tools.Prin...

2015-04-21 20:22:00 247

转载 Java:references initialized

If you want the references initialized,you can do it:  1.At the point the objects are defined.This means that they'll always be initialized before the constructor is called  2.In the construc...

2015-04-21 17:47:00 160

转载 Java:Variable argument lists

1 class A { 2 } 3 4 public class NewVarArgs { 5 6 static void printArray(Object... args) { 7 for (Object obj : args) { 8 System.out.print(obj + " ...

2015-04-20 17:08:00 150

转载 Java:数组的赋值实际上是引用

1 public class ArrayOfPrimitives { 2 3 public static void main(String[]args){ 4 int[]a1={1,2,3,4,5}; 5 int[]a2; 6 a2=a1; 7 8 for(int...

2015-04-20 13:40:00 218

转载 Java:thinging in java p158 exercise 1

Create a class with a String field that is initialized at the point ofdefinition, and another one that is initialized by the constructor. What isthe difference between the two approaches. 1...

2015-04-19 11:05:00 182

转载 Java:this示例2

The this keyword is also useful for passing the current object to another method: 1 class Person { 2 public void eat(Apple apple) { 3 Apple peeled = apple.getPeeled(); 4 ...

2015-04-19 00:49:00 167

转载 Java:this示例

1 public class Leaf { 2 3 int i = 0; 4 5 Leaf inceament() { 6 i++; 7 return this; 8 } 9 10 void print() {11 System.out.println("i=...

2015-04-19 00:33:00 116

转载 Java:thinging in java p154 exercise 10

题目A vampire number has an even number of digits and is formed by multiplying apair of numbers containing half the number of digits of the result. Thedigits are taken from the original number ...

2015-04-17 12:20:00 103

转载 Java:thinging in java p153 exercise 9

1 import java.util.Scanner; 2 3 public class Fibonacci { 4 5 int fibo(int n) { 6 switch (n) { 7 case 1: 8 return 1; 9 case 2:10 ...

2015-04-17 11:50:00 135

转载 Java:label的使用(while循环)

1 package java_test; 2 3 public class labelWhile { 4 5 public static void main(String[] args) { 6 int i = 0; 7 outer: while (true) { 8 System.ou...

2015-04-17 00:37:00 659

转载 Java:label的使用(for循环)

1 package java_test; 2 3 public class LabeledFor { 4 5 public static void main(String[]args){ 6 int i=0; 7 outer: //Cannot have statement here 8 ...

2015-04-17 00:27:00 1679

转载 Java:thinging in java p139 exercise4

1 public class primeTest { 2 3 public static void main(String[] args) { 4 5 int i, j; 6 for (i = 3; i < 100; i++) { 7 for (j = 2; j < i; j++...

2015-04-16 21:32:00 94

转载 java:各基本数据类型的操作

1 //THINGING IN JAVA P123 2 3 package java_test; 4 5 //Tests all the operators on all the primitive data types: 6 //to show which ones accepted by the Java compiler. ...

2015-04-16 00:26:00 150

转载 java:对象赋值

1 package exercise; 2 3 class Tank 4 { 5 int level; 6 } 7 8 public class Assignment{ 9 public static void main(String[]args){10 Tank t1=new Tank();11 ...

2015-04-13 22:28:00 90

转载 错误:Syntax error on token ";", { expected after this token

if语句应写在某个代码块,或者方法中,否则实例化后,无法执行。所以eclipse纠错系统认为你少了一个大括号转载于:https://www.cnblogs.com/taoxiuxia/p/4382582.html...

2015-04-01 00:42:00 1391

转载 java包

1.Scanner:导包import java.util.Scanner;2.如果想要编译使用JNLP API的程序,那就必须在类路径中包含javaws.jar文件,这个文件在JDK的jre/lib子目录下。转载于:https://www.cnblogs.com/taoxiuxia/p/4378711.html...

2015-03-30 17:48:00 88

转载 vs2010格式化代码

ctrl+k,ctrl+f转载于:https://www.cnblogs.com/taoxiuxia/p/4374682.html

2015-03-28 19:38:00 270

转载 自定义View添加滚动条注意事项

布局文件部署好后,注意在自定义的MyView中重写一个方法1 public void onMeasure(int widthMeasureSpec, int heightMeasureSpec) {2 setMeasuredDimension(800, 2000);3 }转载于:https://www.cnblogs.com/taoxiuxia/p/...

2015-03-27 19:34:00 92

转载 可垂直和水平滚动的视图

1 <ScrollView xmlns:android="http://schemas.android.com/apk/res/android" 2 android:layout_width="match_parent" 3 android:layout_height="match_parent" > 4 5 <Horiz...

2015-03-26 20:57:00 262

转载 toast用法

默认用法Toast.makeText(getApplicationContext(), "默认Toast样式",Toast.LENGTH_SHORT).show();转载于:https://www.cnblogs.com/taoxiuxia/p/4369885.html

2015-03-26 20:00:00 76

转载 Android学习之路(转载)

2015-03-26http://www.stormzhang.com/android/2014/07/07/learn-android-from-rookie/转载于:https://www.cnblogs.com/taoxiuxia/p/4367563.html

2015-03-26 00:47:00 135

转载 第六章 编程练习

第一题 1 #include<iostream> 2 #include<cctype> 3 using namespace std; 4 int main() 5 { 6 char arr[80]; 7 char ch; 8 cin.getline(arr,80); 9 int i=0;1...

2014-12-07 22:04:00 106

转载 cctype中的字符函数

函数名称返回值isalnum()如果参数是字母数字,即字母或者数字,函数返回trueisalpha()如果参数是字母,函数返回trueisblank()如果参数是水平制表符或空格,函数返回trueiscntrl()如果参数是控制字符,...

2014-12-07 21:02:00 90

转载 第六章 复习题

1 #include<iostream> 2 using namespace std; 3 int main() 4 { 5 char ch; 6 int ct1,ct2; 7 ct1=ct2=0; 8 while((ch=cin.get())!='$') 9 {10 cout&...

2014-12-07 20:55:00 105

转载 第六章

1 #include<iostream> 2 using namespace std; 3 int main() 4 { 5 char ch; 6 int spaces=0,total=0; 7 cin.get(ch); 8 while(ch !='.')//注意使用单引号。 9 {10 ...

2014-12-06 21:46:00 87

转载 第五章 编程练习

第一题 1 #include<iostream> 2 using namespace std; 3 int main() 4 { 5 int a,b,sum=0; 6 cin>>a>>b; 7 for(int i=a;i<=b;i++) 8 sum+=i; 9 ...

2014-12-06 19:50:00 136

转载 使用new创建动态数组

使用new创建动态数组例如:1 int *psome=new int[10];要将数组的类型和元素的数目告诉new即可。new运算符返回第一个元素的地址。当程序使用完new分配的内存块时,要使用delete释放。1 delete[]psome;方括号的意思就是释放整个数组。总之,使用new和delete时,应遵守:1、不要使用delet...

2014-12-06 15:51:00 336

转载 vector 和array的用法

模板类vector模板:1 vector<typename>vt(n_elem);其中n_elem可以是整型常量,也可以是整形变量。如:1 #include<vector>2 ...3 using namespace std;4 vector<int>vi;//大小为05 int n;6 cin>&...

2014-12-06 15:29:00 147

转载 5.5,5.6

5.5循环和文本输入使用cin进行输入 1 #include<iostream> 2 int main() 3 { 4 using namespace std; 5 char ch; 6 int count=0; 7 cout<<"enter the characters,enter #to qu...

2014-12-04 16:46:00 78

转载 5.1,5.2

5.1 for循环c++对for循环的调整。允许for(int i=0;i<5;i++)这样的情况出现这样做的优点是变量i只出现在for循环中。a++,++a;a++表示使用a的当前值,然后将a加1;++a表示先将a+1,然后使用新的值。 1 #include<iostream> 2 #include<string&...

2014-12-04 15:37:00 173

转载 第四章.编程练习

第一题 1 #include<iostream> 2 #include<string> 3 using namespace std; 4 int main() 5 { 6 char fristname[20]; 7 char lastname[20]; 8 char grade; 9 int ...

2014-12-02 17:02:00 171

转载 第四章复习题

1、1 char actors[30];2 short betsic[100];3 float chuck[13];4 long double dipsea[64];2、1 array<char,30>actor;2 array<short,100>bestic;3 array<float,13>chuck;...

2014-12-02 14:07:00 149

转载 4.9,4.10

4.9类型组合 1 #include<iostream> 2 struct years 3 { 4 int year; 5 }; 6 7 int main() 8 { 9 using namespace std;10 11 years s1,s2,s3;12 s1.year=1998;1...

2014-12-02 12:07:00 166

空空如也

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除