Fixed bug: missing [k] on line 52