61 dfa 實現敏感詞過濾
阿新 • • 發佈:2017-05-31
引用 nbsp bsp 概念 pre clas logs code println
基本的概念
Class class=null 【只是在棧內存中有了指向,堆內存並沒有分配內存】
Class class=new Class()【棧內存中有了指向(引用),堆內存也分配了內存】
map的嵌套實現樹
Map<object,object> map = new HashMap<>();
Map<Object, Object> map = new HashMap<>(); Map<Object, Object> temp =map; temp.put(1,1); Map<Object, Object> map1 = new HashMap<>(); map1.put(1,"child"); temp.put("child",map1); temp = map1; Map<Object, Object> map2 = new HashMap<>(); map2.put(2,"child2"); temp.put("child2",map2); System.out.println(map);
61 dfa 實現敏感詞過濾