HackerTrans
TopNewTrendsCommentsPastAskShowJobs

timakro

no profile record

comments

timakro
·4년 전·discuss
Small correction: contrary to what the post claims this does not compile:

    fn main() {
        let s = String::from("hello");
        foo(s);
        println!("{}", s);
    }

    fn foo(le_string: String) -> String {
        println!("{}", le_string);
        le_string
    }
This does, which is probably what the author meant:

    fn main() {
        let s = String::from("hello");
        let s = foo(s);
        println!("{}", s);
    }

    fn foo(le_string: String) -> String {
        println!("{}", le_string);
        le_string
    }
Great post!
timakro
·4년 전·discuss
Amazon makes it easy to sell especially with FBA. That's as much a good thing as it can be misused. It allows new businesses to get started when they cannot afford to handle shipping to customers themselves.
timakro
·4년 전·discuss
So it turns out the default on Debian is mawk which does NOT support Unicode. Thanks for pointing that out. This simple test gives different results for gawk and mawk.

  $ echo 'ö' | awk '{print length}'
timakro
·4년 전·discuss
I believe no distro actually ships this version of awk by default. They ship GNU awk which has Unicode support anyways.
timakro
·4년 전·discuss
Even though I'm a prospective developer I read the title as "realizations I had when writing in a public library". I was hoping for tips or insights when working in public spaces.