mardi 27 décembre 2016

Should a random string generation method be static?

I want to make a function that puts several strings together to form a random name. I also want this functionto be callable from any class. All it does is to assign a name to an instance.

Should this be a static function, or is it better to make a name-giver instance every time you generate a new name, and why is it so?

I want to focus on using as little memory as possible.




Aucun commentaire:

Enregistrer un commentaire