Ò׽ؽØͼÈí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

javaдµÄÑî»ÔÈý½Ç

import javax.swing.JOptionPane;
public class San {
    /**
     * @param args
     */
    public static void main(String[] args) {
        // TODO Auto-generated method stub
           String rowString;
           int rowInt;
          
           rowString = JOptionPane.showInputDialog("lines£º");
           rowInt = Integer.parseInt(rowString);
          
           int triangle[][]=new int[rowInt][rowInt * 2 - 1];
          
           for(int i = 0;i < rowInt;i++){
                  for(int j = 0;j < rowInt * 2 -1;j++){
                      triangle[i][j] = -1;
                  }
              }
          
           for(int i = 0;i < rowInt;i++){
               triangle[(rowInt * 2 - 1) / 2 - i][i] = 1;
               triangle[(rowInt * 2 - 1) / 2 - i][rowInt * 2 - 1 - i - 1] = 1;
     


Ïà¹ØÎĵµ£º

JAVA²¢·¢±à³Ìʵ¼ù

×î½ü¶ÁÍê<Java²¢·¢±à³Ìʵ¼ù>,ÎÞÒÉÕâÊÇÒ»±¾ºÃÊé,ËüʹµÃÎÒ¶ÔÏß³Ì,Ëø,ÒÔ¼°Óë²¢·¢Ïà¹ØµÄ
һЩ֪ʶÌåϵ¸ü¼ÓÍ걸,Ïл°²»¶à˵,ÏÂÃæÎÒϵͳÊáÀíÁËÏÂÀïÃæµÄһЩÀíÂÛÒªµã,ÏàÐÅʵ¼ùÉÏ
Ãæ,´ó¼Ò»ò¶à»òÉÙ¶¼»áÓÐÌå»á,ÄÇôÓÃÀíÂÛµÄ֪ʶµã½«Êµ¼ùÌå»áÁýÂçÆðÀ´,½«»áÐγɸü¼ÓÀιÌ
ºÍÍ걸µÄ֪ʶÌåϵ,ÖÁÉÙÎÒÕâôÈÏΪ,дÕâһƪ±Ê¼ÇÒ²ÊÇÓÃÒÔ ......

JAVA¶¯Ì¬´úÀíÄÚ²¿ÊµÏÖ


JAVA¶¯Ì¬´úÀíÄÚ²¿ÊµÏÖ
Ò»¡¡´úÀíÉè¼Æģʽ
´úÀíģʽΪĿ±ê¶ÔÏóÌṩһÖÖ´úÀíÒÔ¿ØÖƶÔʵ¼Ê¶ÔÏóµÄ·ÃÎÊ¡£ÔÚijЩÇé¿öÏ£¬Ò»¸ö¿Í»§²»Ïë»òÕß²»ÄÜÖ±½ÓÒýÓÃÁíÒ»¸ö¶ÔÏ󣬶ø´úÀí¶ÔÏó¿ÉÒÔÔÚ¿Í»§¶ËºÍÄ¿±ê¶ÔÏóÖ®¼äÆðµ½ÖнéµÄ×÷Óá£
ΪÁ˱£³ÖÐÐΪµÄÒ»ÖÂÐÔ£¬´úÀíÀàºÍʵ¼ÊίÍÐÀàͨ³£»áʵÏÖÏàͬµÄ½Ó¿Ú£¬ËùÒÔÔÚ·ÃÎÊÕß¿´À´Á½ÕßûÓÐË¿ºÁµÄÇ ......

JAVA ×Ö·û´®±àÂë×ܽá

 String newStr = new String(oldStr.getBytes(), "UTF-8");    
 
javaÖеÄStringÀàÊÇ°´ÕÕunicode½øÐбàÂëµÄ£¬µ±Ê¹ÓÃString(byte[] bytes, String encoding)¹¹Ôì×Ö·û´®Ê±£¬encodingËùÖ¸µÄÊÇbytesÖеÄÊý¾ÝÊÇ°´ÕÕÄÇÖÖ·½Ê½±àÂëµÄ£¬¶ø²»ÊÇ×îºó²úÉúµÄStringÊÇʲô±àÂ뷽ʽ£¬»»¾ä»°Ëµ£¬ÊÇÈÃϵ ......

JavaÉè¼Æģʽ ¹¤³§·½·¨£¨Factory Method£©Ä£Ê½

1.2 ¹¤³§·½·¨£¨Factory Method£©Ä£Ê½
 
    ¹¤³§·½·¨Ä£Ê½ÊÇÀàµÄ´´½¨Ä£Ê½£¬ÓÖ½ÐÐéÄâ¹¹Ôì×Ó£¨Virtual Constructor£©Ä£Ê½»òÕ߶à̬ÐÔ¹¤³§£¨Polymorphic Factory£©Ä£Ê½¡£
    ¹¤³§·½·¨Ä£Ê½µÄÓÃÒâÊǶ¨ÒåÒ»¸ö´´½¨²úÆ·¶ÔÏóµÄ¹¤³§½Ó¿Ú£¬½«Êµ¼Ê¹¤×÷ÍƳٵ½×ÓÀàÖС£
 
1.2.1 ¹¤ ......

Java EE 6ÒýÈëµÄJPA 2.0ËÄ´óÐÂÌØÐÔÏê½â

¡¾51CTO¾«Ñ¡ÒëÎÄ¡¿Java EE 5ƽ̨ÒýÈëÁËJava³Ö¾Ã»¯API£¨Java Persistence API£¬JPA£©£¬ËüΪJava EEºÍJava SEÓ¦ÓóÌÐòÌṩÁËÒ»¸ö»ùÓÚPOJOµÄ³Ö¾Ã»¯Ä£¿é¡£JPA´¦Àí¹ØϵÊý¾ÝÓëJava¶ÔÏóÖ®¼äµÄÓ³É䣬Ëüʹ¶ÔÏó/¹Øϵ£¨O/R£©Ó³Éä±ê×¼»¯£¬JPAÒѾ­±»¹ã·º²ÉÓã¬ÒѾ­³ÉΪÊÂʵÉϵÄO/R³Ö¾Ã»¯ÆóÒµ±ê×¼¡£
Java EE 6´øÀ´ÁËJPAµÄ×îа汾 &mdash ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ