Do not use for loop initial declarations

This fixes this error when compiled with GCC:

  error: ‘for’ loop initial declarations are only allowed in C99 or C11 mode

Instead, initialize variables in the beginning of function body.
Move max and square functions implementations to .c file

This prevents errors from linker like this one:

  ./src/norm.o: In function `max':
  norm.c:(.text+0x0): multiple definition of `max'
  ./src/main.o:main.c:(.text+0x90): first defined here
  ./src/norm.o: In function `square':
  norm.c:(.text+0x20): multiple definition of `square'
  ./src/main.o:main.c:(.text+0xb0): first defined here
  collect2: error: ld returned 1 exit status
Merge pull request #1 from mitya57/master

Fix compilation with GCC