TCRT5000 is an IR sensor module which outputs different values depending on the reflectivity of surface in front of sensor. This example shows how to get data from the IR sensor.
I redrawn the circuitry and found that the 4.7K resistor could be positioned like this: I don't understand why this resistor is there and can I replace two 10K and 4.7k resistors with one 3.3K ...