Sounds like what I’d split up into visualization (presenting the data you care about in a meaningful way), introspection (making it easy to look inside the state of a program), and rapid feedback (“what’s this do? does this even work?”).

There are environments that try to give you those things, in varying mixes. The specific tools you’d reach for tend to vary by language. But if you get some poking around the Web time, maybe look into:

  • Jupyter / IPython Notebooks: Lets you embed “cells” of code into a notebook. The output shows below each cell. The latest version lets you “get inside” the cells even more so than before. Started with Python, but now supports seemingly everything.
  • Light Table: An editor that tries to provide simultaneous docs and feedback as you edit.
  • Elm: A Web programming environment that provides rapid, helpful feedback when you go wrong and lets you record, replay, and rewind event history as you edit the program.
  • IPython: A “smart” shell environment for Python.
  • pry: Lets you poke around inside a paused Ruby program.

More general tool categories:

  • Whatever sort of “debugger” comes with your toolset. These tend to let you look around and try stuff from inside your program.
  • Whatever sort of “REPL” comes with your toolset. This lets you try stuff, finetune it, then graduate the working snippet to your file for safekeeping.
  • Editor modes / extensions. These can provide smart autocomplete, docs for everything in situ in your editor, and “run this snippet of code” or “throw this in a REPL so I can play with it”.
  • Testing systems. Think of them kinda like a primitive Jupyter notebook if you’re working by example (given this, when I do that, then it oughta…), or an evil genius tester if you’re doing generative/property-based tests (given any filepath you can throw at this function…).

The truth is most programming environments are painfully primitive, and it sometimes seems a miracle we ever get anything working. There are some interesting “forks in the road” that might better match your needs, in the form of image-based systems like Pharo.