GNU social JP
  • FAQ
  • Login
GNU social JPは日本のGNU socialサーバーです。
Usage/ToS/admin/test/Pleroma FE
  • Public

    • Public
    • Network
    • Groups
    • Featured
    • Popular
    • People

Embed Notice

HTML Code

Corresponding Notice

  1. Embed this notice
    Karsten Johansson (ksaj@infosec.exchange)'s status on Thursday, 09-Jan-2025 18:32:11 JSTKarsten JohanssonKarsten Johansson
    in reply to
    • Elias Mårtenson
    • Ásbjørn 🏳️‍🌈

    @loke @praetor I was secretly hoping you'd provide your even-more-alien language version. :ablobdj:

    Question, since you're a little smarter than me: I learned that in Lisp programming, the preferred method is code is easiest understood by the (human) reader. So in this context, one of the cond conditions is (< years 1) which obviously could go below zero, but we humans know it never would.

    If a dog is less than a year old, a (human) reader would say "less than a year old", versus the tighter (= years 0) plus however many months.

    I think (hope?) the compiler would adjust it exactly the same way.

    What is considered better code - the human way or the computer way of writing it?

    EDIT: Also, yea, I think you need to prefix the 0.0+ or something (it didn't work for me). The result for 1 year 10 months is 45/2, which is quite a bizarre way to describe a dog's age. I just changed the 10 to 10.0 in the input and it gave me more civilized results. So it can be tamed somehow.

    EDIT2: Okay I got it. It works outside the brackets. It definitely needs to be there since 45/2 is such an unintuitive answer.

    In conversationabout 6 months ago from infosec.exchangepermalink
  • Help
  • About
  • FAQ
  • TOS
  • Privacy
  • Source
  • Version
  • Contact

GNU social JP is a social network, courtesy of GNU social JP管理人. It runs on GNU social, version 2.0.2-dev, available under the GNU Affero General Public License.

Creative Commons Attribution 3.0 All GNU social JP content and data are available under the Creative Commons Attribution 3.0 license.