Step 1: General equation of the circle.
The general equation of a circle is:
\[
x^2 + y^2 + 2gx + 2fy + c = 0
\]
Since the circle passes through the origin, we substitute \( x = 0 \) and \( y = 0 \) into the equation:
\[
0 + 0 + 2g \cdot 0 + 2f \cdot 0 + c = 0 \quad \Rightarrow \quad c = 0
\]
Thus, the equation becomes:
\[
x^2 + y^2 + 2gx + 2fy = 0
\]
Step 2: Apply the x- and y-intercepts.
We are given the x-intercept is 3 and the y-intercept is -5. For the x-intercept, set \( y = 0 \), and for the y-intercept, set \( x = 0 \). Substituting these values:
For the x-intercept, \( y = 0 \):
\[
3^2 + 0^2 + 2g \cdot 3 + 2f \cdot 0 = 0 \quad \Rightarrow \quad 9 + 6g = 0 \quad \Rightarrow \quad g = -\frac{3}{2}
\]
For the y-intercept, \( x = 0 \):
\[
0^2 + (-5)^2 + 2g \cdot 0 + 2f \cdot (-5) = 0 \quad \Rightarrow \quad 25 - 10f = 0 \quad \Rightarrow \quad f = \frac{5}{2}
\]
Step 3: Final equation.
Substitute \( g = -\frac{3}{2} \) and \( f = \frac{5}{2} \) into the equation:
\[
x^2 + y^2 - 3x + 5y = 0
\]
Step 4: Conclusion.
Thus, the equation of the circle is \( \boxed{x^2 + y^2 - 3x + 5y = 0} \).