when private constant?


is right private consistent following situation:



say i have diversion lives non-static startinglives variable. during start diversion i set lives non-static equal startinglives variable. i customarily it:



private var lives:int = 0;
private var startinglives:int = 3;

private duty startgame():void
{
lives = startinglives;
}


(example formula actionscript btw)



my doubt - should unequivocally be:



private var lives:int = 0;
private const starting_lives:int = 3;

private duty startgame():void
{
lives = starting_lives;
}


startinglives seems puzzled change during runtime, should i const, change behind non-static turns out constant?



update: settle seems good constant, nonetheless amdfan's idea competence wish bucket value config file?



Comments

Popular posts from this blog

list macos calm editors formula editors

how hibernate @any-related annotations?

why does floated <input> control floated component slip over too distant right ie7, nonetheless firefox?