4 ms·
Speaking as a sci-fi author, who thinks about this quite a bit: there will be more kinds of programming, but it'll all pretty much resemble what we already have
by derefr 16y ago
Speaking as a sci-fi author, who thinks about this quite a bit: there will be more kinds of programming, but it'll all pretty much resemble what we already have. It will be faster and easier, and use (or "waste", depending on your perspective) lots more resources. It would be completely predicated on the technology, not in "alien thinking"; if given a tutorial, humans could easily program the alien computers the same way the aliens could, after struggling with concepts that are about equivalently difficult to recursion or pointer arithmetic.
The kind of programs we know today (encoding static text segments using a tower of abstractions and compilers) would still continue to exist. What we today call "programming" as a whole, will be what aliens call "embedded programming"—the kind you do under severe resource-constraints, where every gate must be secure, reliable, and could be hit with hard radiation at any time. We'd easily be able to understand these programs, given an appropriate disassembler. They would likely be written mostly by constraint-solving AIs, however, not tediously by aliens, who have better things to do. Aliens would, however, check them over out of paranoia/"defense-in-depth." They would be intensely parallel: imagine how NASA shuttle software works, with several independently-contracted codebases on independent hardware voting on each decision—but multiply the scales a millionfold.
Most programs, however, would not be "embedded"; they could expect to rely on a "silly" amount of resources. They would be inscrutable, mostly JIT-genetically-evolved from small "goal scripts" (which themselves would still, indeed, resemble human source code—clear and exact communication of rules and intent within a business domain survives no matter the language used.) They would rely on a "universal library" of "common sense", both in process knowledge (algorithms, protocols) and semantic knowledge (datatypes, fixtures, "facts" in the RDF sense) that would allow programmers to actually write "Do What I Mean" programs as well as could ever be achieved.
There would only be a single "programming language", for the same reason that we, today, have a Unicode character encoding. All programs would be internally stored in something resembling S-expressions (just a binary-encoded tree), and represented, textually or graphically (or audially or kinesthetically or experientially or somatically or telepathically...) through a bijective transformation. Every identifier in a program would be a universally-unique resource-locating ID (i.e. something that is both a UUID and a URL) allowing for importing of live code from external (network) libraries, cross-program optimization and symbolic unification, global API versioning, and removal of all "name clashes."
Also, a bonus sociological perspective: there would be living software—like with carbon-based life, we would classify software into "plants" (natural resources that we care about mostly as an enabler), "animals" (feeling but unthinking goal-directed objects that we think should have some, but not all, the rights of sentients) and "people" (which would have just the same rights bio-people do.) "Animal" software would have control systems that mimic (or simply are) emotions; an alien Roomba would indeed be considered a pet. But in the converse view, the aliens would consider genetically programming carbon-based plants and animals to have symbiotic functions, just as we currently live in symbiosis with robots and machines. They might all be ultra-vegans, for the simple reason that any combination of flavor, texture, and nutritional content could be turned into the fruit of a plant (a symbiotic arrangement), and so would abhor the non-symbiosis with which we consume our own environment.
- sgt 16y agoInteresting ideas. May I ask which books you have written?
- gjm11 16y agoafter struggling with concepts that are about equivalently difficult to recursion or pointer arithmetic I think that's a bit optimistic. Even within the realms of human programming languages, competence may require struggling with concepts that are as difficult as, say, monads or virtual destructors or Prolog cuts or abstract factory factory factory factories or call-with-current-continuation. Those are all at least one step up from recursion or pointers. I don't see any reason to expect that alien languages would be nearer in conceptual difficulty to C than to Haskell or C++ or Scheme or Prolog.