set lookat from a raycast

i want the object that the raycast hits so i can put it in the lookat as a variable anyone know how

You can access the collider of hit by the the RaycastHit during the raycast. And then so transform.