<rt id="bn8ez"></rt>
<label id="bn8ez"></label>

  • <span id="bn8ez"></span>

    <label id="bn8ez"><meter id="bn8ez"></meter></label>

    posts - 33,  comments - 11,  trackbacks - 0
     1import java.io.BufferedReader;
     2import java.io.IOException;
     3import java.io.InputStreamReader;
     4import java.io.PrintStream;
     5import java.text.DecimalFormat;
     6import java.text.NumberFormat;
     7import java.text.SimpleDateFormat;
     8import java.util.Calendar;
     9
    10public class MyEclipseRegister{
    11
    12private static final String L = "Decompiling this copyrighted software is a violation of both your license agreement and the Digital Millenium Copyright Act of 1998 (http://www.loc.gov/copyright/legislation/dmca.pdf). Under section 1204 of the DMCA, penalties range up to a $500,000 fine or up to five years imprisonment for a first offense. Think about it; pay for a license, avoid prosecution, and feel better about yourself.";
    13
    14public static void main(String[] args){
    15    BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
    16    String userId = null;
    17    int intLicenseNum = 1;
    18    String strLicenseNum = null;
    19    boolean bProFlag = true;
    20    String strProFlag = null;
    21
    22    while ((userId == null|| ("".equals(userId.trim()))) {
    23      System.out.print("用戶名: ");
    24      try {
    25        userId = br.readLine();
    26      }

    27      catch (IOException ioe1){
    28      }

    29    }

    30    System.out.print("注冊碼可用的用戶數量(默認 1, 最大 999): ");
    31    try {
    32      strLicenseNum = br.readLine();
    33    }

    34    catch (IOException ioe2)
    35    {
    36    }

    37
    38    Object nf = new DecimalFormat("000");
    39    if ((strLicenseNum == null|| ("".equals(strLicenseNum.trim())))
    40      strLicenseNum = ((NumberFormat)nf).format(intLicenseNum);
    41    else {
    42      strLicenseNum = ((NumberFormat)nf).format(Integer.parseInt(strLicenseNum));
    43    }

    44
    45    System.out.print("個人版 或 標準版(默認 個人版, n 標準版): ");
    46    try {
    47      strProFlag = br.readLine();
    48    }

    49    catch (IOException ioe3) {
    50    }

    51    if ((strProFlag != null&& (!("".equals(strProFlag.trim())))) {
    52      bProFlag = false;
    53    }

    54
    55    Calendar cal = Calendar.getInstance();
    56    cal.add(12);
    57    cal.add(6-1);
    58    SimpleDateFormat sdf = new SimpleDateFormat("yyMMdd");
    59
    60    String need = userId.substring(01+ "Y" +
    61      ((bProFlag) ? "E3MP" : "E2MY"+ "-100" + strLicenseNum + "-" +
    62      sdf.format(cal.getTime()) + "0";
    63    String dx = need + "Decompiling this copyrighted software is a violation of both your license agreement and the Digital Millenium Copyright Act of 1998 (http://www.loc.gov/copyright/legislation/dmca.pdf). Under section 1204 of the DMCA, penalties range up to a $500,000 fine or up to five years imprisonment for a first offense. Think about it; pay for a license, avoid prosecution, and feel better about yourself." + userId;
    64    int suf = decode(dx);
    65    String code = need + suf;
    66    System.out.println("注冊碼: " + change(code));
    67}

    68
    69  static int decode(String s) {
    70    int i = 0;
    71    char[] ac = s.toCharArray();
    72    int j = 0;
    73    for (int k = ac.length; j < k; ++j)
    74      i = 31 * i + ac[j];
    75
    76    return Math.abs(i);
    77  }

    78
    79  static String change(String s) {
    80    if ((s == null|| (s.length() == 0))
    81      return s;
    82    byte[] abyte0 = s.getBytes();
    83    char[] ac = new char[s.length()];
    84    int i = 0;
    85    for (int k = abyte0.length; i < k; ++i) {
    86      int j = abyte0[i];
    87      if ((j >= 48&& (j <= 57))
    88        j = (j - 48 + 5% 10 + 48;
    89      else if ((j >= 65&& (j <= 90))
    90        j = (j - 65 + 13% 26 + 65;
    91      else if ((j >= 97&& (j <= 122))
    92        j = (j - 97 + 13% 26 + 97;
    93      ac[i] = (char)j;
    94    }

    95    return String.valueOf(ac);
    96  }

    97}

    98
    posted on 2011-04-26 10:28 方濤升 閱讀(509) 評論(1)  編輯  收藏 所屬分類: j2ee

    FeedBack:
    # re: MyEclipse5.5注冊機
    2012-10-10 13:04 | lxg
    hao dong xi   回復  更多評論
      
    <2011年4月>
    272829303112
    3456789
    10111213141516
    17181920212223
    24252627282930
    1234567

    常用鏈接

    留言簿(2)

    隨筆分類

    隨筆檔案

    文章分類

    搜索

    •  

    最新評論

    閱讀排行榜

    評論排行榜

    主站蜘蛛池模板: 亚洲最大成人网色香蕉| 亚洲一区在线免费观看| 国产视频精品免费视频| 尤物永久免费AV无码网站| 亚洲高清国产拍精品熟女| 四虎影院在线免费播放| 亚洲精品无码一区二区| 永久黄网站色视频免费| 色窝窝亚洲AV网在线观看| 亚洲av高清在线观看一区二区 | 最新精品亚洲成a人在线观看| jizz免费观看视频| 国产成人精品日本亚洲网站| 无码av免费一区二区三区试看| 亚洲AV无码精品色午夜在线观看| 91精品全国免费观看含羞草| 亚洲mv国产精品mv日本mv| 毛片a级毛片免费观看免下载| 久久久久久亚洲精品无码| 国产成人精品久久亚洲高清不卡 | 99热在线日韩精品免费| 亚洲AV日韩AV永久无码久久| 成年免费大片黄在线观看岛国| 成年女人免费视频播放体验区| 午夜国产大片免费观看| 一级做a爰片久久毛片免费陪| 久久久久国产成人精品亚洲午夜 | 久久国产亚洲精品麻豆| 日本免费大黄在线观看| 亚洲日本一线产区和二线 | 亚洲黄色三级视频| 日本免费一区尤物| 毛片在线全部免费观看| 日韩亚洲人成在线| 久久久久久亚洲精品不卡| 1a级毛片免费观看| 免费的黄色网页在线免费观看| 亚洲bt加勒比一区二区| 国产成人免费一区二区三区| 无码精品国产一区二区三区免费| 亚洲国产成人久久精品大牛影视 |