it depends on religions, areas, time... some big religions consider it a sin, some countries ban it,... with deep and wise reasons.
it also depends on each person. like Buddhist consider drink alcohol is a sin, but there is a famous Chinese legendary Buddha named Te Cong still drinking day by day, but he still keep his soul clear.
as far as I know that almost all religions considers gambling is a sin even in some countries gambling is legal but for the particular religions that obviously gambling is a sin but although for some people already know it they would not care about that and still do a gambling because gambling has already become their hobbies