@Valgo and @Rawrbear have taken the words out of my mouth
Here is the reference for Codea which might give you an idea of some of the things you can do with it (like how one might have a quick browse through the blocks on Hopscotch)
(This is a pic from inside the app)
And indeed you can tinker around with projects (these are some sample ones)
And yep they have dependencies, so you can have code from other projects without having to rely on copying and pasting it in I think, I'm not too sure on how it works since I haven't been able to make use of it yet, but the feature is there, they say (only in full version though):
There is a Scratchpad version that used to be free, but they changed the price of that to around $8 Australian dollars (im under the impression that it is around $5 for US for some idea of reference). But it has been pretty great for getting started. From that, I did go on to buy the full version, after seeing it would be worth it for my case considering how I was using it.
Swift Playgrounds has been really great for learning, and it's free, but I have no idea how to get started on making something on my own from scratch, which I was really eager to do when I got it. But the tutorials are great and you definitely can make your own projects, i'm just not sure how to do it.
I also know @Stradyvarious has recommended Tynker and ReadyMaker but I don't know too much about them, I believe they're free too but would need to check.
Edit: sorry I think I may have misunderstood what you were looking for with projects if you are wondering anything about any of the things I've mentioned, I'd be more than happy to expand on them and also, thanks for tagging –yep was glad to hear about this and join in