import java.io.*; public class SimpleTagMaker { public static void main(String[] args) throws IOException { String[] words = { "Computer", "Duke", "Fun", "Interesting", "Knowledge", "Science", "University", "Work", }; int[] tagClass = { 5, 10, 20, 15, 18, 5, 3, 25 }; CSSMaker css = new CSSMaker(); String header = css.makeHeader(); String footer = css.makeFooter(); File temp = File.createTempFile("tagger", ".html"); FileWriter fw = new FileWriter(temp); fw.write(header); for (int k = 0; k < words.length; k++) { String htm = css.makeHTML(words[k], tagClass[k]); fw.write(htm); } fw.write(footer); fw.flush(); BareBonesBrowserLaunch.openURL("file://" + temp.getAbsolutePath()); } }