#Function Default Values
5 messages · Page 1 of 1 (latest)
In C++, you don't name the parameters during the call. You just fill them in order:
drawVerticalLine(69)
drawVerticalLine(69, "BH")
drawVerticalLine(69, "BH", "420")
5 messages · Page 1 of 1 (latest)
I have 2 default values but how should I fill up the last one?
void drawVerticalLine(int length, string filler=BH, string corner=BC);
drawVerticalLine(69, corner=420);
In C++, you don't name the parameters during the call. You just fill them in order:
drawVerticalLine(69)
drawVerticalLine(69, "BH")
drawVerticalLine(69, "BH", "420")