⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 exclude.java~12~

📁 英语的自动句子权值计算程序
💻 JAVA~12~
字号:
package abstrac;

import java.util.Hashtable;


public class Exclude {
    //public Exclude(){
        String[] remove={"the", "a", "an",
        "this", "that", "we", "it", "our", "my", "us", "his", "they", "their",
        "them", "me", "I", "him", "you", "your", "he", "she", "my", "her",
        "been", "be", "am", "is", "are", "was", "were",
        "shall", "cannot", "may", "have", "had", "might", "can", "could",
        "will", "would", "should", "must", "has",
        "unless", "while", "or", "than", "neverthless", "if", "when", "therefore",
        "whenever", "because", "and", "but", "although", "since", "so",
        "to", "of", "for", "with", "per", "in", "by", "without", "from", "between",
        "as", "on", "upon", "through", "about", "above", "across", "against",
        "along", "among", "around", "behind", "below", "beneath", "besides","beside",
        "beyond", "down", "during", "except", "into", "near", "off", "over", "past",
        "round", "since", "throughout", "till", "until", "towards", "under", "up", "within",
        "two", "three", "four", "five", "fift", "six", "seven", "eight", "nine", "ten", "teen",
        "thus", "always", "often", "yet", "also", "instead", "almost", "as", "enough", "not",
        "very", "there", "too", "rather",null};

   // }
   public Hashtable comp(String[] source) {
        Hashtable ha = new Hashtable();
        boolean isExclude = false;
        for (int i = 0; i < source.length; i++) {
            if (ha.containsKey(source[i])) {
                continue;
            }
            else {
                for (int j = 0; j < remove.length; j++) {
                    if (source[i].equalsIgnoreCase(remove[j])) {
                        ha.put(source[i], 1);
                        break;
                    }
                    else
                    {ha.put(source[i], 0);}
                }

            }

        }
      // for(int i=0;i<source.length;i++){
         // System.out.print(source[i]+":");
         // System.out.println(ha.get(source[i]).toString());
       //}

        return ha;
    }

}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -