can someone tell me how to draw pattern in cpp with explaination