My first thought would be to make a simple infinite iterator function for z.
the boilerplate of that iterator code aside, I think this solves the scope
problem and the cognitive load problem and makes it look more elegant, but I
know iterators are expensive. I wonder how expensive for this
I have tried IE, Firefox and Chrome on my Win7 64bits with and without proxy,
but in these months it is very hard for me to load
[https://forum.nim-lang.org](https://forum.nim-lang.org)/ or any posts url. No
error is displayed, all these web browsers just finished with a blank page but
the
[há
hắng]ư)[http://forum.gamevn.com/forums/cac-quang-cao-khac.394/create-thread](http://forum.gamevn.com/forums/cac-quang-cao-khac.394/create-thread))
I noticed the following example in the nim manual to demonstrate how to use an
untraced object:
type
Data = tuple[x, y: int, s: string]
# allocate memory for Data on the heap:
var d = cast[ptr Data](alloc0(sizeof(Data)))
# create a new string on the
Happy new year and many thanks to the contributors!
Nim + Intel's proprietary C/C++ compiler == easy benchmark wins over languages
married to LLVM.
original article:
[https://atilanevesoncode.wordpress.com/2018/12/31/comparing-pythagorean-triples-in-c-d-and-rust](https://atilanevesoncode.wordpress.com/2018/12/31/comparing-pythagorean-triples-in-c-d-and-rust)/
here's nim version I proposed: see
I had a similar issue, a windows install prior to installing choosenim, so
after updating with choosenim, nim -v was unchanged. I deleted the old install
and their paths and then it showed the choosenim version ok.
Having thought about this for a while, I am not advocating for a fix. I was
hesitant to define the == func at all since it is comparing keys but not
values, It is called set-equal? in MIT/Scheme wttree, not equal?. I only
considered adding it to make the unit tests line up with other Nim set
Hi all, I have updated nim using "choosenim". CMD showed me that update was
successful. But printing "NimVersion" shows "0.19.0". Do i miss anything ?
He has a different opinion to you, it doesn't matter. Jut have a little laugh
if he complains about Nim. It's not worth losing a friendship over.
The one and only advantage of C# and VB.Net is the best in class IDE visual
studio. If Nim has an IDE like visual studio, then Nim is the king among all
languages. Really.
Oh funny, one reason I was attracted to Nim was because it _was_ immediately
readable to me, that its focus was about readability and representation. This,
compared to rust, for example, which makes me start clenching my teeth. If a
language goes down that rabbit hole, then it should just be
Seems like a compiler bug. Workaround:
func `==`*(s1: BBTree, s2: BBTree): bool {.inline.} =
## Returns true if both `s1` and `s2` have the same keys and set size.
result = isSubset(s1, s2) and len(s1) == len(s2)
Run
Sure, here are the relevant bits:
type
BBTree*[K,V] = ref object # BBTree is a generic type with keys and
values of types K, V
## `BBTree` is an opaque immutable type.
left: BBTree[K,V] # left subtree; may be nil
right: BBTree[K,V]
Pardon me but it seems that you should change friends rather than language.
What your friend said about Nim being incomprehensible for people who don't
know Nim is simply ridiculous BS.
If I were in your place -[and](https://forum.nim-lang.org/postActivity.xml#and)
\- for whatever weird reason
First, I'd like to thank you for all the answers. You really gave me some good
knowledge about how I could approach my friend. However, he's found another
argument I really can't beat with my own knowledge. He says Nim's unreadable
for programmers coming from other languages.
My main
I had a similar gang of "friends" a couple of years ago. We used to hang out on
an IRC network that they ran, eventually I decided to just leave it because
having them complain about Nim every time I wanted to discuss one of my
projects became far too tiring.
Many of the languages they were
I don't see a reason why it would fail to compile.
Can you also add your BBTree and isSubSet type declaration so that we can
reproduce a minimal working example?
sorry to reply in this old posts. but I am still (I almost have spent one year)
looking for GUI solution(s) which have already exposed many widgets/controls
for windows OS. So I really want to know
1\. which is the latest sciter binding for nim? Google finds
https://github.com/oskca/nsciter
in the VB lib, which calls functions in 32bits DLL, there are something I am
not very sure
1\. many arguments are declared as LONG in the VB files. I found that LONG is
signed 64-bit integers on
Sadly you have to use an `Option` in this case. I'm afraid the to macro doesn't
support anything else.
@novikov You ran into this because you've attempted to reinstall choosenim. You
already have it installed so just run `choosenim update stable` like the
release blog post says:
> choosenim supplies 0.19.0
Until this is fixed, after the installation run:
$ choosenim update stable
Run
**choosenim** supplies 0.19.0
[https://nim-lang.org/install_unix.html](https://forum.nim-lang.org/postActivity.xml#https-nim-lang-org-install-unix-html)
> Many thanks to all the contributors who made these releases possible and Nim
> thrive.
Here are some quick numbers:
* 237 backported[1] commits since `v0.19.0` tag (September 26th), more than
2.5 commits per day on average
* 48 contributors
> there are rumors that with this release
Not sure if it's correct to place suggestions... But if collective imports from
a directory could be nested it were more consistent in my opinion.
> First of all, he states that not having such an indentation-based syntax
> allows for more freedom ...
He is right in that but only in one regard: Having explicit block markers (like
{ and } or `begin` and `end`) allows for (visually largely unstructured)
"streams" of code. If that were
28 matches
Mail list logo