I have a 5 volt converter but I also need 3.3 volts, what should I do?
18 V is 6 V above the maximum input voltage of your converter IC. So, that won't do.
I don't understand what you mean with &quot;I don't know where to place the resistor. The datasheet extensively answers that – even on the very first page.
There's plenty of other DC/DC converter ICs from the same manufacturer. Every single of their datasheets has an example circuit. Even better: TI.com has what they call &quot;WeBench power designer&quot; and it draws the schematics for you and gives you the right components.


implicitly calculated resistors for any given Vin.

The resistors have nothing to do with Vin.

I want to add a buck converter to a circuit to reduce the voltage to 5V and then to 3.3V.

You can do that, but it seems unnecessary, as it puts additional load on the 5V rail, and saves you no components. Also, it's worse for noise, but I doubt that's relevant here.