# Debugging in Ruby

**URL:** <https://www.ruby-forum.com/t/debugging-in-ruby/176536>\
**Category:** Ruby\
**Created:** [October 1, 2009, 7:49pm UTC](https://www.ruby-forum.com/t/debugging-in-ruby/176536 "2009-10-01T19:49:57Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![yousef\_1987](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/y/51bf81/32.png) [@yousef\_1987](https://www.ruby-forum.com/u/yousef_1987)\
**Post date:** [October 1, 2009, 7:49pm UTC](https://www.ruby-forum.com/t/debugging-in-ruby/176536/1 "2009-10-01T19:49:57Z")

</div>

hi everybody

I a new in Ruby P.ming , I want to know what are the benefits of  
using Debugging technique.

by create breakpoint …

---

<div class="post-metadata">

**Author:** ![yousef\_1987](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/y/51bf81/32.png) [@yousef\_1987](https://www.ruby-forum.com/u/yousef_1987)\
**Post date:** [October 2, 2009, 1:04am UTC](https://www.ruby-forum.com/t/debugging-in-ruby/176536/2 "2009-10-02T01:04:20Z")

</div>

Yousef J. wrote:

> hi everybody
> 
> I a new in Ruby P.ming , I want to know what are the benefits of  
> using Debugging technique.
> 
> by create breakpoint …

The benefits of debugging are not particular to programming in any  
language. If you have written some code you want to be able to test it.  
Having a window into seeing what is going on in the code is very helpful  
in eliminating faults and getting the code to work as required.

Check out [ruby-debug](http://bashdb.sourceforge.net/ruby-debug.html)

David

---

<div class="post-metadata">

**Author:** ![yousef\_1987](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/y/51bf81/32.png) [@yousef\_1987](https://www.ruby-forum.com/u/yousef_1987)\
**Post date:** [October 3, 2009, 2:46am UTC](https://www.ruby-forum.com/t/debugging-in-ruby/176536/3 "2009-10-03T02:46:02Z")

</div>

Yousef Programmer wrote:

> hi everybody
> 
> I a new in Ruby P.ming , I want to know what are the benefits of  
> using Debugging technique.
> 
> by create breakpoint …

A breakpoint allows you to stop execution of your code inside a  
debugger, and  
thus you can inspect variables, the call stack and execution flow to  
determine  
where the code is not executing as you might expect it to.

You can also step through the execution of your code one line at a time  
after  
the breakpoint, step into and over function call, inspect return values,  
and a  
lot more.

debugging is (usually) used to analyze code to fix bugs, but you can  
also use a  
debugger to gain deeper knowledge of code someone else wrote.

–  
Kind Regards,  
Rajinder Y.

[http://DevMentor.org](http://DevMentor.org)  
Do Good ~ Share Freely
