A lot of it depends upon your districts policy. In most states students have to earn a certain number of core credits (math, science, history, and English) every year. Certainly, if summer school is provided anyone failing these classes would probably have to take summer school. In addition, states (and school districts) require certain number of credits for graduation, and students with too few credits might have to take summer school.
In our district, students can now only take summer school if they've failed. And generally, they can only take core classes or CAHSEE prep classes (I teach in CA; the CAHSEE is our high school exit exam). So, the options are incredibly limited: Algebra, English, Earth Science, etc. I don't even think any level of history is offered.
The sad part is, this has all arisen from budget cuts. When I attended school, I remember taking Health and Driver's Ed during summer school. It worked perfectly for me, because I had no room for them in my regular schedule. Now however, students don't have that option. They have to take Driver's Ed at lunch, leaving their 4th period class early to make it on time. So, they miss out on instruction in that class, plus any activities at lunch. All in an attempt to save money.
It all depends on what your district will allow. Some districts only allow students to make up credits for core classes that were failed, while others offer a wider range of classes, covering electives. You'll have to check with your principal.
Each situation is going to be different because there are different factors to consider. If the student needs the credit to graduate then he or she will probably need to go to summer school. It is possible for the student to retake the course the next school year but then they will be a year behind. If the student is failing multiple courses then summer school is inevitable if they want to graduate on time.
For core classes (such as science, math, and english), summer school is usually suggested so that the student does not fall behind. Physical education or spanish may be a bit different.
As previously noted, this is an issue decided on a case by case basis. All school districts do contain some provision for what happens if a student fails a particular course. Mandatory summer school attendance is one path that is pursued by many in ensuring that children understand the importance of doing well in classes during the school year and to ensure that the material has been retaught. I think that schools are investigating how to make summer school more meaningful and relevant, for while students might not be able to fullt cover everything outside of the classroom setting, it is important that some skills and functional development is enhanced within the outside of class environment. In addition to this, with state standardized based educational reform taking such a hold on schools, the investment into summer school programs that "work" and have been successful is becoming of tantamount importance.
That depends on the rules of your school district or college, as they vary greatly. If you are in a program that has required courses and/or group requirements, you may have to repeat a course in order to graduate. Some summer schools are only for classes a student has failed, and others let you get ahead in your coursework. In the high school I teach in, for example, there are electives that any student can take, that will give them credit toward graduation, but some of the required courses can only be taken by those who have failed them (otherwise they become overcrowded.) You are in college--usually you can take whatever you like. Ask upperclassmen for info for your particular college, as well as the registrar.
in my school the teacher give us hard homework
In my school we have health / gym, foreign language, and earth science graduation requirements. So yes, if someone were to fail one of these classes, they might have to take it during the summer. (Obviously, with the exception of gym!) Granted, this class won't be in a traditional classroom but would rather be an online version taken by students all across the state. If there is time and room in a person's schedule, they can always plan to re-take the classes in the following school year.
It can depend on your school or district. Sometimes in bigger cities they either have summer school or instead of summer school they only have the option of taking the class as a running start version to earn the credit back! Some towns may be too small and cannot support summer classes