1.Belief
Remember that most problemsetter ans coordinator don't like to hack right solution by the shortage of time.Most tasks are easy for right code to pass.
2.Simplified ways
There are simple ways to make your code fast,like a faster input or output,you can find out them while practising.
3.Reduce operations
Find out what is useless and delete them.Maybe it's slow because they are done while running but not make sence.
4.Merge calculations
Some calculation can be done together,then put them together.
5.Faster calculations
Some calculations are slow,try to replace them with faster ones.
6.Make use of precalculations
precalculate more before core calculation can make the code faster.Sometimes return value of functions can be precalcutated by just a small range,but can make the code fast.It can even make time complexy better.
7.Maybe we need a better algorithm
Sometimes a task can be solved by a faster algorithm,this may leads to unfriendliness of slower solutions.So if you found another faster algorithm,you can rewrite the code of it and then see if it's enough fast.









#pragma GCC optimize("O3")