I was doing an example of Bisection method applied to $f(x) = \cos(x) - xe^{x}= 0$,
I did all correctly upto 4th step , but after that i don't understand how it is considering the interval of $(0.5,0531)$ as i am getting it to be $(0.562,0.625)$ as $f(0.562)>0$ and $f(0.625)<0$ , and i saw other sources the answer is still coming to be $0.517$
Any ideas or help!
As pointed out in the comments, it seems you are using degrees instead of radians for cosine. Letting $\operatorname{cosd}$ be cosine in degrees and $\cos$ be cosine in radians, one has
$$\cos(0.562)\approx0.84619,\quad\operatorname{cosd}(0.562)\approx0.99995$$ $$\cos(0.562)-0.562e^{0.562}\approx-0.13966,\quad\operatorname{cosd}(0.562)-0.562e^{0.562}\approx0.01410$$