So if a Pokémon used Struggle, what fraction would your Pokémon get hurt by?
Generation I Struggle inflicts damage, and the user receives recoil damage equal to ½ of the damage done to the target. Struggle will automatically be used by a Pokémon that has no usable moves but is ordered to attack. Struggle is capable of striking a critical hit. If the user of Struggle attacks first and knocks itself out due to recoil damage, the opponent will not attack or be subjected to recurrent damage during that round. If Struggle breaks a substitute, the user will take no recoil damage. In Stadium, no recoil damage is taken if Struggle knocks out an opponent.
Generation I Struggle inflicts damage, and the user receives recoil damage equal to ½ of the damage done to the target. Struggle will automatically be used by a Pokémon that has no usable moves but is ordered to attack. Struggle is capable of striking a critical hit.
If the user of Struggle attacks first and knocks itself out due to recoil damage, the opponent will not attack or be subjected to recurrent damage during that round. If Struggle breaks a substitute, the user will take no recoil damage.
In Stadium, no recoil damage is taken if Struggle knocks out an opponent.
Generations II and III Struggle now has a maximum of 1 PP instead of 10 (16 with PP Ups), and its recoil damage is equal to ¼ of the damage the attack did to the opponent. The user will take recoil damage even if Struggle breaks a substitute, or if its Ability is Rock Head or Magic Guard.
Generations II and III Struggle now has a maximum of 1 PP instead of 10 (16 with PP Ups), and its recoil damage is equal to ¼ of the damage the attack did to the opponent.
The user will take recoil damage even if Struggle breaks a substitute, or if its Ability is Rock Head or Magic Guard.
Generation IV The user now takes ¼ of its maximum HP as recoil damage, regardless of how much damage the attack did to the opponent. This ¼ is rounded down except in the case of Shedinja, who will knock itself out with recoil damage.
Generation V onward Struggle's ¼ calculation is now subject to standard rounding; for example, a Pokémon with 201 maximum HP using Struggle will have its recoil round down to 50, but 202 or 203 HP will round up to 51 recoil damage.
Struggle (Bulbapedia)
Generation I Struggle inflicts damage, and the user receives recoil damage equal to ½ of the damage done to the target. Struggle will automatically be used by a Pokémon that has no usable moves but is ordered to attack. Struggle is capable of striking a critical hit. If the user of Struggle attacks first and knocks itself out due to recoil damage, the opponent will not attack or be subjected to recurrent damage during that round. If Struggle breaks a substitute, the user will take no recoil damage. Self-inflicted recoil damage from Struggle from the previous turn can be countered if the opponent did not make a move on the following turn.
source