Consider the given equation,
sinθ+cosθ=√2 …(1)
Taking square both sides,
sin2θ+cos2θ+2sinθcosθ=2
1+2sinθcosθ=2
2sinθcosθ=1
sinθcosθ=12 ……(2)
Now, divided by cosθ in equation 1st , we get
tanθ+1=√2cosθ ….(3)
Again divided by sinθ in equation 1st, we get
1+cotθ=√2sinθ ….(4)
Add equation 1st and 2nd , we get
tanθ+cotθ+2=√2cosθ+√2sinθ
tanθ+cotθ=√2.(sinθ+cosθsinθcosθ)−2 ……(5)
Now, from equation 1st ,2nd and 5th ,we get
tanθ+cotθ=√2.⎛⎜ ⎜ ⎜⎝√212⎞⎟ ⎟ ⎟⎠−2
tanθ+cotθ=2
Hence, this is the answer.