#include <unistd.h>
void rush00(int x, int y);
int main()
{
    rush00(1,5);
    return 0;
}

void    ft_putchar(char a)
{
    write(1, &a, 1);
}


void    rush00(int x, int y)
{
        int     c_x;
        int     c_y;

        c_y = 0;
        while (++c_y <= y)
        {
                c_x = 0;
                while (++c_x <= x)
                {
                        if (c_y == 1 || c_y == y)  
                        {
                                if (c_x == 1 || c_x == x)  
                                        ft_putchar('o');
                                else
                                        ft_putchar('-');
                        }
                        else if (c_x == 1 || c_x == x)  
                                ft_putchar('|');
                        else if (c_x != 1 || c_x != x)
                                ft_putchar(' ');
                }
                ft_putchar('\n');
        }
}


Embed on website

To embed this project on your website, copy the following code and paste it into your website's HTML: