Guest User

Untitled

a guest
Jun 21st, 2018
95
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.38 KB | None | 0 0
  1. /*5. 產生 String objects array,並為每個元素指派一個字串。以 for 迴
  2. 圈將所有內容印出來。*/
  3. public class Practice5 {
  4.  
  5. public static void main(String[] args) {
  6. String[] S = {"A","B","C","D","E","F","G"};
  7. for(int i = 0 ; i < S.length ; i++) {
  8. System.out.println("S["+i+"]= " + S[i]);
  9. }
  10. }
  11.  
  12. }
  13. /*我竟然成功了 寫出來眼淚都要流下來了*/
Add Comment
Please, Sign In to add comment