in linux i used something like
autocmd FileType cpp nmap <buffer> <F5> :w<bar>!g++ -o %:r % && ./%:r<CR>
but since windows uses back slashes i thought i should try something like
autocmd FileType cpp nmap <buffer> <F5> :w<bar>!g++ -o %:r % && .\\%:r<CR>
or
autocmd FileType cpp nmap <buffer> <F5> :w<bar>!g++ -o %:r % && ./\%:r<CR>
but none of them seem to give desired results .can someone who understands vim scripts better help me figure this out . I've also tried other combinations but nothing seems to work .rather than gamble some more thought I might ask