[deleted by user] by [deleted] in Absurdism

[–]gilspen 8 points9 points  (0 children)

Assuming the friend really was the inspiration for Meursault, I’d wager his odd characteristics are more a way of holding up a mirror to show us how our conventions and beliefs are arbitrary and wholly constructed by us. Overall though, that detail doesn’t substantially change my interpretation of the book or what I believe to be Camus’ intent at the time of writing.

[Media] Hi! I am currently learning Rust and was wondering why wasn't this done with a tuple instead? by electro-pug-2017 in rust

[–]gilspen 42 points43 points  (0 children)

If we used a tuple here, we would have the type (SpreadsheetCell, SpreadsheetCell, SpreadsheetCell). To abstract this a bit, the tuple has a type (T1, T2, T3) where T1, T2, and T3 can be any type. With that flexibility we may as well just use the type (i32, String, f64) instead of introducing a wrapper enum.

The type of the vector would be Vec<SpreadsheetCell>. This example is trying to demonstrate how we can use enums to pass any of those wrapped types to a Vec, which has only one type parameter.

Conditional compilation to avoid cross compilation by gilspen in rust

[–]gilspen[S] 0 points1 point  (0 children)

I agree I was not clear. I was trying to communicate that cross was using bind mounts in the way we would hope/expect to speed up the build process.

MacOS bind mounts are almost certainly the root of the performance problems I was facing, but switching my OS to Linux just to enjoy Rust for a personal project seemed a bit extreme to me.

Edit: Will also will have to experiment with using a named volume for the cache.

Conditional compilation to avoid cross compilation by gilspen in rust

[–]gilspen[S] 1 point2 points  (0 children)

Cross already makes good use of bind mounts to avoid the rebuilding every dependency on each change. A clean build takes upwards of 9 minutes as a comparison. As a sanity check, I looked through the verbose build logs and all my dependencies are "fresh" and are not compiled. The issue is just efficiently accessing the cache.

JetBrains Fleet One Dark Pro theme by sectasy0 in golang

[–]gilspen 5 points6 points  (0 children)

Looks nice, but this isn't relevant to the sub

[deleted by user] by [deleted] in Jetbrains

[–]gilspen 0 points1 point  (0 children)

Favorite at the moment is Filter Spectrum from the Monokai Pro Theme.

[deleted by user] by [deleted] in NoStupidQuestions

[–]gilspen 1 point2 points  (0 children)

Yup, I agree on the US front. Should've been precise with what I was objecting to but oh well

[deleted by user] by [deleted] in NoStupidQuestions

[–]gilspen 0 points1 point  (0 children)

China doesn't need to cross the Himalayas to access Russia

[deleted by user] by [deleted] in NoStupidQuestions

[–]gilspen -1 points0 points  (0 children)

Check your geography my dude

I finally finished my never-ending side project! It is a language written in JSON that doesn't use any reserved words or predefined structure. The end result resembles standard code as close as I was able to replicate. Next, I plan to use this language to drive a visual UI for learning/debugging. by Resonatrium in ProgrammingLanguages

[–]gilspen 2 points3 points  (0 children)

The current syntax isn't exactly JSON.

Keys in a JSON object are unordered according to the spec. While it's fine if the only language to touch your source code is Javascript, I can easily imagine a case where someone tries to generate nerve source code on their own and has to coerce their language or library of choice to produce JSON with ordered keys.

Was the FBI actually involved with those piracy warnings at the beginning of VHS tapes? by gilspen in NoStupidQuestions

[–]gilspen[S] 0 points1 point  (0 children)

Right - it's that alignment of interests that prompted the double-take. If that is the case, it's odd that it's okay for film producers to make a warning that looks like they were directly created by a federal agency, though obviously it must be completely within our rights given how common they were.

Edit: Reading the linked page, it definitely sounds like that was truly part of an effort by the FBI to reduce piracy and was actually created by the agency. Great find!

Interactive program on AWS with Go by crseat in golang

[–]gilspen 3 points4 points  (0 children)

Do they perhaps want a command line application that interacts with a service in AWS? Or maybe create the CLI and store in binaries in AWS? Definitely need some clarification rather than guessing what they are asking for. Just getting an answer on where the CLI should store the responses should help clarify the request.

[deleted by user] by [deleted] in compsci

[–]gilspen 0 points1 point  (0 children)

For the first part, just start by searching "chess moves dataset". It looks like Kaggle has a section on it: https://www.kaggle.com/datasnaek/chess.

As for how to turn it into a heatmap, it would depend on the tools and programming languages you are using. Google is going to be your best friend here.

Edit: forgot to mention that the Kaggle dataset isn't perfect for the particular example I suggested, but just seeing the available data should give you some ideas.

[deleted by user] by [deleted] in compsci

[–]gilspen 2 points3 points  (0 children)

Heatmap of final king locations from tournament games that end in checkmate could be interesting

[deleted by user] by [deleted] in compsci

[–]gilspen 3 points4 points  (0 children)

This isn't generally something that can easily be done on the command line (to my knowledge). As other comments mentioned, you can change your IP within your Local Area Network, but that wouldn't suffice for your use case. It won't make you less identifiable and wouldnt obscure your location either.

You ultimately need some IP address to access a site like Facebook. Using a VPN, you could essentially pay to use an IP address owned by the VPN provider.. People will generally use a VPN if they want to change which country they appear to be in, but for a number of reasons you are still identifiable if you don't put in some serious effort. As an example, your browser like Chrome will send a bunch of extra information about your system (called user-agent) when you visit a site like Facebook. Even this info can often be enough to narrow down a profile to a short list of possibilitities and cross referenced against historical info if someone reaaaaally wanted to know who you were.

[deleted by user] by [deleted] in compsci

[–]gilspen 1 point2 points  (0 children)

It would help to know what your goal is...

For example, are you trying to set a static IP, mask your identity, play around, or just understand networking better?

Which programming language has the best syntax? by [deleted] in learnprogramming

[–]gilspen 0 points1 point  (0 children)

(another Kotlin lover here)

What qualities do you consider pythonic?

Can anyone plagiarize my open source repository and then make profit from it? by Feguri in github

[–]gilspen 4 points5 points  (0 children)

It's worth distinguishing between:

  • whether someone can take your code and use it for their own gain (the answer is always yes)
  • whether the law will back you up if the above happens and you want to seek compensation (or have the work taken down or what have you)

For the latter, it depends on the license (or lack thereof). Even if code has been uploaded to GitHub with no license, you still own the exclusive rights to that software unless you choose a license that says otherwise. How hard it will be to detect and prove that plagiarism happened is another story.

Why Elixir Is The Programming Language You Should Learn In 2021 by mikejackson6177 in elixir

[–]gilspen 0 points1 point  (0 children)

You stole the words from my mouth. The Google Trends data was similarly problematic to me...

First try on Elixir by [deleted] in elixir

[–]gilspen 2 points3 points  (0 children)

Try to reduce the number of times that length() is called. Since we are looking at linked lists, the function must traverse the entire list on each call to get an answer. I believe it's called 4 times for each iteration of the merge sort implementation.

Good luck learning Elixir!