Rooting out Hamas terrorists from Gaza is a crazily impossible task - nobody in the US military command would ever consider such a venture.
Building a 8 lane highway to Hawaii would be easy in comparison.
I think it is doable and the plan like this can work:
Stage one: put pressure on population by introducing a complete blockade (practically done)
Stage two: after a couple weeks of conditioning open safe routs to designated places in Gaza (cordoned by Israelis) and to Egypt for women and children only. Separate men who want to leave in filtration camps and investigate everybody towards connection with Hamas.
Stage 3: simultaneously with the stage 2, build tent cities with the help from outside donors to house civils for about 6 months.
Stage 4: After most of civilians left, introduce a double ring complete blockade on the remaining of Gaza.
Stage 5: Let Hamas fighters rot for a few months without electricity, water, food and under constant harassment by aerial bombardment, drones and snipers.
Stage 6: Clean up the remaining resistance pockets with special forces methodically going from sector to sector for a couple of months.
Stage 7: Spray all territory first with a disinfectant and then with a deodorant.
Stage 7: Put every penny going from international donors to all Palestinian territories under supervision of a special international body that will oversee all spending as well as re-building and the general economic development of Palestinian territories. Confiscate all weapons, dismantle local police, and create international police force to keep the order.
Stage 8: After ten years of rebuilding, development, and re-education under revised school curriculums hold first municipal elections.
Stage 9: After 20 years hold general elections and referendums.