-7

c++ 中的相同代码是什么样的,或者最接近它的代码是什么样的?

public class Skill{

     public Skill(String name){

     }

     public static Map<String, Skill> getSkills(){
          Map<String, Skill> skills = new Map<String, Skill>();
          skills.add("Endurance", new Skill());
          return skills;
    }
}
4

1 回答 1

2
std::map<std::string,Skill*> skills;
skills["Endurance"] = new Skill();
于 2013-05-01T10:49:50.083 回答