First, the error message says that min not found, while you say that you're using gcc !!!, are you missing something here?
However, maybe you're missing adding gcc to your PATH env variable. Add MinGW's bin directory to PATH (it should solve your problem).
Besides, in your .vscode/tasks.json, change:
"command": "c:\\MinGW\\bin\\gcc.exe"
To
"command": "gcc"