▲ 9 r/Julia

How do i make a function with multiple named optional arguements?

I'm making a calendar thing, and i have a struct containing fields of years, months, days, etc. and I'd like to have one single addTime! method that works on any time unit. I'd like to be able to call
addTime!(callendarVar, months=10)
addTime!(callendarVar, years=5)
addTime!(callendarVar, months=10, days=20)

I've already got the logic down but i'm having trouble writing a working declaration which would allow me to use these disordered optional arguements based on their names. Any advice?

EDIT: the trick was to add a semicolon between the static arguement and the optional arguements. How i was meant to figure that out without taking a spyglass to every character in the docs - i have no idea.

reddit.com
u/Szymon_Patrzyk — 14 days ago

Please tell me i didnt just dream this song up.

I remember hearing a colabsong between Lord of the Lost and Powerwolf where Cheis Harms was singing either one of Powerwolfs songs with "wild" in the title or incense and iron. I have the sound of it stuck in my brain and i remember seeing it on yt music half a year ago, but now i cannot find anything at all about it.

The only thing i'm finding now is kiss of the cobra king, which is cool, but a completely different vibe than i remember.

reddit.com
u/Szymon_Patrzyk — 24 days ago

How do i swap operating systems while putting the original in a VM?

I currently have an activated windows 10 PC running as my OS, i'd like to find a way to Have this PC run linux with virtualbox containing this instance of windows.

I currently have used disc2vhd to virtualize the drive containing windows and stored it on an external hard drive, but i'm worried that if i override the windows system now i might end up losing the key.

Are there any other steps or safety measures that i'm missing before i continue?

reddit.com
u/Szymon_Patrzyk — 2 months ago
▲ 1.6k r/memeframe

Please clap. it took nearly an hour to translate and this thing doesn't even have a past tense

u/Szymon_Patrzyk — 2 months ago