package jp.co.jid.exBasic;

public class MyString {

	public void beep(int count) {
		for (int i = 0; i < count; i++) {
			System.out.println("ビーーー");
		}
	}

	public void branch(int func) {
		switch (func) {
			case 1:
				System.out.println("おはようございます");
				return;
			case 2:
				System.out.println("こんにちは");
				return;
			case 3:
				System.out.println("こんばんは");
				return;
			case 4:
				System.out.println("おやすみなさい");
				return;
			case 5:
				System.out.println("また明日");
				return;
			default:
				System.out.println("さようなら。。。");
		}
	}

	public String concat(String[] strArray) {
		StringBuffer sb = new StringBuffer();
		for (String str : strArray) {
			sb.append(str);
		}
		return sb.toString();
	}

	public String replace(String csvString) {
		return csvString.replace(",", "\t");
	}
}
