So your applications live in a snow globe?
Basically yes.
The clever part of the program, which takes all the hard work to write, takes
one pattern of bits, and shuffles it about. Sometimes it returns a new pattern
of bits, sometimes it modifies the original one, that's just a minor detail.
These bit shuffling functions ideally go in separate source files. There's no
reason ever to use non-portable constructs, except for silly marginal cases
like expecting eight bits in an unsigned char where the portable version is
fiddly and provides no practical benefit. There in C. Anything that supports
call to C can set up one pattern of bits, call them, and get back the resulting
pattern of bits.
The patterns are of course human-meaningful in almost all cases. They might
represent an empty crossword grid and a list of English words, and the output
is a filled grid with interlocking words. But the computer doesn't know it's
creating a crossword. All it sees is bits it has to shuffle about until it
reaches a situation where there are no blank cells and every continuous line
of more than one cell matches one of the patterns in the list.
That then has to be hooked up to IO so that you can see the result. This is
usually pretty trivial if you've got a decent IO library. Writing a decent
IO library isn't trivial of course, it's difficult in a different way. Baby X
is an example of an IO library.