首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > JAVA > Java Exception >

The seon argument is inserte into the ontents of this string buffer at the posit

2014-02-22 
The seon argument is inserte into the ontents of this string buffer at the position iniate by offset

The seon argument is inserte into the ontents of this string buffer at the position iniate by offset The length of this string buffer inreases by one

以下是我的程序,请各位大哥给小妹指点一下啦
public class GongTest
{
private int strLength;
private int rows;
private char sigleStr;
private int index;
private StringBuffer sb=new StringBuffer();
private boolean flag=false;
private boolean syFlag=false;

public String creStr(String str, int cols)
{

strLength=str.length();
rows=strLength/cols;
int count=0;
int sbLength=0;
char senStr=' ';
char backStr=' ';
char backCh=' ';
for(int i=0;i<strLength;i++)
{

sigleStr=str.charAt(i);
flag=false;
syFlag=false;
sbLength=sb.length();
// System.out.println(sbLength);
if(sigleStr==','||sigleStr=='.'||sigleStr=='?'||sigleStr=='!'||sigleStr==')' {
// System.out.println(sigleStr+"gong");
index=str.indexOf(sigleStr);
senStr=str.charAt(index+1);         

热点排行