Float division returns "inf" and 0
Assuming the speed of sound is of the order of 330&nbsp;m/s, you expect
the round-trip to the target and back to last about 1.8&nbsp;ms. Then

recieved = pulseIn(echo, HIGH);


should give a value close to 1,800, and

recieved = recieved * 1000000.0;


should make received something like 1.8&nbsp;×&nbsp;109.
Then

speed_of_sound = (2*target_distance)/recieved;


gives a speed of sound of 3.3&nbsp;×&nbsp;10−10. It is the
correct value if you want that speed in meters per picosecond, but this
is inconsistent with your program printing “m/s” after the value.

The Arduino's Serial.print() is quite dumb with floating point
numbers. It defaults to printing two digits after the decimal point,
irrespective of the order of magnitude of the number. Thus, anything
smaller than 0.005 gets printed as “0”.

I don't quite understand why you got ∞ on the first loop. Looks like
pulseIn() missed the pulse and returned zero, in which case the speed
is computed as 0.6&nbsp;÷&nbsp;0&nbsp;=&nbsp;∞.

The solution is to compute received as

recieved = pulseIn(echo, HIGH) * 1e-6;


This can be remembered by thinking that a quantity (round-trip time) is
a numeric value (pulseIn(echo, HIGH)) multiplied by a unit (1e-6,
which stands for “microseconds”).