Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • Jul 01 2018 17:34
    @greggirwin banned @BIjeuca_twitter
  • Dec 03 2017 05:53
    @PeterWAWood banned @matrixbot
  • Sep 28 2016 12:20
    @PeterWAWood banned @TimeSeriesLord
TLG
@TheLastGuard
it is possible to include a file written in Red/System in normal Red
and Hi, sorry
hiiamboris
@hiiamboris
#system [#include %file.reds]
TLG
@TheLastGuard
thanks
Gregg Irwin
@greggirwin
Welcome @TheLastGuard. No need to apologize.
ams0_0
@ams02468
Hi, I had a question how can I give this example two inputs?
a: system/options/args

     -p: func [x y] [

         print rejoin [{ren "}x{" "}y{"}]]


            if find a "-p" [ 

                  remove a

                     -p remove a a ]
hiiamboris
@hiiamboris
what inputs?
system/options/args contains all the arguments from command line
ams0_0
@ams02468
@hiiamboris i solved the problem thanks anyway
François Jouen
@ldci
What’s wrong in this function?
bitExtract: function [
    number     [integer!]
    n        [integer!]
    p        [integer!]
][
    ((1 << n) - 1) AND (number >> (p - 1))
]
print bitExtract 140 3 6 print bitExtract 140 3 4
OK : we get 4 and 1
But print bitExtract 45 3 6 print bitExtract 45 3 4
I’m waiting for 6 and 6 and I get 1 and 5
hiiamboris
@hiiamboris
45 is 101101, how do you expect 6 and 6?
François Jouen
@ldci
@hiiamboris Code given by Gif code table :)
hiiamboris
@hiiamboris
54 maybe not 45
those bloggers...
ams0_0
@ams02468
hi hope you guys have a good day, I wanted to know what code editor you use for red? I want to change my editor and I need your experience
François Jouen
@ldci
@ams02468 Depends on your OS. With macOS, I use sublime Text or BBEdit.
Gregg Irwin
@greggirwin
UltraEdit.
Boleslav Březovský
@rebolek
Vim
hiiamboris
@hiiamboris
@ams02468 CudaText (cross-platform)
I dropped Sublime for it's too hard to extend, and decided against UltraEdit for it's too sluggish for my taste.
ams0_0
@ams02468
10q 4 the answers you gave, very helpful
GaryMiller
@GaryMiller
Notepad++
dsunanda
@dsunanda
Also using Notepad++ .... Recently changed from Programmer's Notepad because it is getting a bit crufty with UNICODE support.
Both have syntax coloring for Rebol (and therefore Red) which is nice.
Jose Luis
@planetsizecpu
Notepad++ + @Ungaretti 's pluggin
ams0_0
@ams02468
Hi, is there a command to show numbers smaller than one number, something like a countdown?
dsunanda
@dsunanda
You could adapt something like this:
 num: 7 repeat n num [print num - n]
6
5
4
3
2
1
0
ams0_0
@ams02468
thx @dsunanda
ams0_0
@ams02468
hey guys why the output of this code is none ?
z: [ 1 2 3 4 5]

a: 1

print z/a
Toomas Vooglaid
@toomasv
@ams02468 z/:a or z/(a)
ams0_0
@ams02468
thx @toomasv
Toomas Vooglaid
@toomasv
:+1:
ams0_0
@ams02468
Hello . there is way to convert the output of code to the string again ?
print checksum "test" 'MD5
dsunanda
@dsunanda
@ams02468 There's not supposed to be :). The point of hashes is that they are a one-way secure function.
MD5 though is so badly broken, that a search on the internet is often all you need:
https://md5.gromweb.com/?md5=098f6bcd4621d373cade4e832627b4f6
test
ams0_0
@ams02468
I wanted to know if red has sup reverse function? anyway thanks @dsunanda