Chat:World/2021-03-30

From CG community
Jump to navigation Jump to search

Default avatar.png akagami101: yo

Default avatar.png qhug8: hi

Default avatar.png qhug8: im in canada

Default avatar.png colbh: hi

kira_kira: normrm2191 guys I need some help w/ the puzzle of the week Im so lost

micoze-stella: i think its puzzle is difficult, too

WOLFRAHH: yeah same here i want some hint with puzzle of the week

davilla: PotW literally has published papers on algorithms to solve it

davilla: ridiculously hard problem, unless n=2

Default avatar.png zukarinkuari2: hi

DanniBoy: i dont get why these people dont share their codes

Default avatar.png kilicmustafa: hi

bobby2: @DanniBoy yeah me neither. Aren't we all here to learn?

JSboss: Fermat's Little Theorem helps with the POTW

KiwiTae: i dont like nuggets

Uljahn: AutomatonNN: damn euler's toadient

AutomatonNN: eulerscheZahl is there a way to see the code in the contest ?

Doju: Well

Doju: I managed to make my new c++ code run

Doju: good news: got 55k nodes vs 2k on python

Doju: bad news: all the nodes are the same pointer :-D

WOLFRAHH: can anybody tell where is my mistake

WOLFRAHH: in power of thor

WOLFRAHH: http://chat.codingame.com/pastebin/573fe8fe-951e-4abf-96cd-c1da4e42a619

Doju: What's the problem?

Doju: WOLFRAHH what's the problem?

WOLFRAHH: falier of 3 and 4th test cases

WOLFRAHH: Doju

jacek: in first you have d+= in second you have d=

Doju: oh right yeah, they should be the other way around

Doju: check north and south first

Doju: because now if you need to go north or south you'll overwrite the variable d

WOLFRAHH: again failier

WOLFRAHH: :sob:

Doju: Are you now checking north and south first?

Doju: so that they have =

Doju: but east and west have +=

WOLFRAHH: yeah i checked

WOLFRAHH: not worked

Doju: hm...

WOLFRAHH: so what for me

Doju: can i see your code again?

WOLFRAHH: http://chat.codingame.com/pastebin/3ba4a3b6-565b-4838-9903-2f44a3e02ec1

Doju: ok i see

Doju: so

Doju: lets think about it

Doju: so you have d=

WOLFRAHH: yeah

KiwiTae: WOLFRAHH indeed if u had to go NW u fail cause your code return N

Doju: you want it to be one of these: N, NE, E, SE, S, SW, W, NW

Doju: you had the right idea with the first version of your code

Doju: but it was just in the wrong order

Doju: you need check N and S first

Doju: so they come at the beginning of the string

Doju: now you're checking them after E and W

Doju: Then whatever d is after checking north and south you just add E or W to the end if needed

KiwiTae: im stuck at 83char in power of thor

WOLFRAHH: hey i do it

KiwiTae: gg

WOLFRAHH: http://chat.codingame.com/pastebin/5c88ecae-8825-4aa4-abae-53599e47a13e

WOLFRAHH: Doju

Doju: Nice!

KiwiTae: WOLFRAHH u can try the episode 2 now

WOLFRAHH: thanks for help

WOLFRAHH: after some time

WOLFRAHH: KiwiTae

WOLFRAHH: thanks for help Doju

jacek: :3

Doju: Now i need some help :d

Doju: How is it possible that ptr is always the same?

Doju: Node child{current_node, value};

               Node* ptr = &child;

Doju: that is in a loop and ptr is always the same address

magaiti: is this c++?

Doju: yes, magaiti

magaiti: you are constructing a temporary object on the stack, then taking address of it

magaiti: you should create the object on the heap, or something

magaiti: use operator new

jacek: i think he knows that. but he wonders why it has the same address

Doju: i did not know that

magaiti: like Node* ptr = new Node{current_node, value};

magaiti: because it's the address of the object on the stack

magaiti: which happens to be the same

magaiti: because it's recreated over and over

Doju: ohh

Doju: this is a really unfriendly language for beginners :p

Doju: thanks

magaiti: it is

Doju: now it works

magaiti: remember to delete your tree when you dont need it

Doju: Right

magaiti: using operator delete. or you could use smart pointers, which is another huge chunk of knowledge

Doju: Erm

magaiti: or you could manage your nodes in an array, and store array index instead of a pointer

jacek: or dont delete at all on CG, no wasted time

Doju: so i need to somehow loop though each node and delete it

magaiti: yeah, kinda, you can do it recursively

Doju: oh yeah i can take the last nodes and do it recursively there, true

jacek: virtual ~MctsMove() { for (auto & m : children) { delete m; } }

Doju: I'm storing the parent instead of the children

Doju: but yeah i think i got it

jacek: oO

magaiti: how do you walk your tree then?

Default avatar.png Mil27Coder: hi

Doju: i don't really need to go from the root outwards ever

Doju: i'm storing the last "layer" of nodes

Doju: and when i run out of time

magaiti: then i humbly assume it's something different from mcts

Doju: just breadth first pretty much

Doju: hahah

Doju: when i run out of time i just evaluate the last nodes, grab the best one and then go towards the root to get the first child node

magaiti: hmm, but

magaiti: your opponent will not make bad moves

magaiti: hopefully for him

magaiti: how do you account for that

magaiti: https://en.wikipedia.org/wiki/Negamax

Doju: The opponent doesn't even exist in my program :D

Doju: This is for the fall challenge

magaiti: ahh well then

Doju: I think considering the opponent's moves is not important enough for me

Doju: given that i'm a beginner in c++

Doju: and i just want to make something that works

magaiti: depends on your definition of "works"

Doju: it has taken me 3 or 4 days just to translate my 500 lines of python to c++

magaiti: compile and doesn't crash != works

Doju: Makes somewhat sensible moves = works

magaiti: "somewhat sensible"

Doju: and can go beyond 3 moves in depth (unlike the python version) :p

jacek: do you have pragmas?

Doju: err

Doju: i'm not really sure what they are but i have #pragma once in all of my headers

Doju: which doesnt really matter since this is all one file now

jacek: as first lines

jacek: #pragma GCC optimize "Ofast,unroll-loops,omit-frame-pointer,inline"

  1. pragma GCC option("arch=native", "tune=native", "no-zero-upper")
  2. pragma GCC target("rdrnd", "popcnt", "avx", "bmi2")

jacek: to tell compiler to compile with optimizations

Doju: thanks

magaiti: do you need popcnt? i think it's included in bmi2

Doju: i'll plug that in and see

Doju: WOAH

jacek: i copy pasted mindlessly

Doju: it's 5 times faster

Doju: hahah

jacek: as everything

magaiti: also i doubt a beginner would use avx and bmi2

jacek: well the compiler could translate some loops to avx itself

magaiti: maybe, doesn't really happens thet much

magaiti: welp i stand corrected,

magaiti: "avx" just increased my rollouts count in clobber from 60k to 100k

Doju: Hmm

Doju: why should I need to manually delete my tree?

Doju: if it gets out of scope on every turn in the game

magaiti: nodes created by operator new dont get out of scope, only their pointers do

JSboss: for those who were asking for more solutions to be published for the weekly challenge, i just posted a JS one

Doju: oh, alright

Doju: Ouch, deleting the nodes is gonna be rather difficult without storing the children

magaiti: i recommend using array instead

magaiti: use push_back() to add node, and store index istead of pointer. then just clear the array

magaiti: as a rule of thumb, you should not use poerator new in modern c++, unless you know what you are doing

Doju: okay

magaiti: so just grow your array of nodes, and store index of parent

Doju: I guess i'll do that

magaiti: then clear the array (resize to 0) when you dont need them any more

magaiti: std::vector<MYNODE>

Doju: got it

Doju: oh dear

Doju: my string, which is supposed to be one of these: "BREW", "CAST", "LEARN", "REST"

Doju: is "-1100793648"

jacek: how do you assign it

Default avatar.png Rens2005: fuck <- is this filtered

Default avatar.png Rens2005: no

Default avatar.png Rens2005: oof

WOLFRAHH: hey what do you say Rens2003

WOLFRAHH: Rens2005

Default avatar.png Rens2005: ?

Default avatar.png Rens2005: i said what i said

WOLFRAHH: you say fuck

Default avatar.png Rens2005: yeah

Default avatar.png Rens2005: who cares

WOLFRAHH: why

WOLFRAHH: plz don't abuse in chat

jacek: it also filters passwords

jacek: ***********

Default avatar.png Rens2005: to see if it was gonna get filtered do you know english?

jacek: see?

Default avatar.png Rens2005: my password: yourmum

linjoehan: pogglepops

Default avatar.png Rens2005: noooooo

Default avatar.png Rens2005: it doesnt

Default avatar.png Rens2005: wow

jacek: only you can see your password

Default avatar.png Rens2005: nooooo

WOLFRAHH: what about jacek he abused the chat

Default avatar.png Rens2005: please dont hack me

linjoehan: hey it dosent filter passwords

jacek: i will hack your checkers bot

Default avatar.png Rens2005: my what?

linjoehan: my checkers bot is weak

linjoehan: wanna see my tetris bot?

Default avatar.png Rens2005: no i want to see ur mom

jacek: :no_mouth:

linjoehan: to late my mom passed 4 years ago

WOLFRAHH: ohh so sad linjoehan

linjoehan: anyway tetrisAI https://github.com/linjoehan/TetrisAI

linjoehan: still gots work to do on it though

jacek: for NES? noice

linjoehan: yeah one day I want to get scores like the pros

jacek: trying RL?

zukarinkuari2: hello

linjoehan: No time for RL

zukarinkuari2: my onee san isnt replying to me anymore:sob:

jacek: your senpai didnt notice you?

WOLFRAHH: can anybody help me to solving fall challange 2020

wlesavo: beam search ezpz

zukarinkuari2: no shes my onee san

zukarinkuari2: not senpai

Insta-x: help, want to solve mars lander using GA but couldn't meet time limit of 100ms, is it even possible?

zukarinkuari2: hmmmm

zukarinkuari2: idek

darkhorse64: If your GA works properly, it will converge towards a good first move. Use that and keep on searching

darkhorse64: If I recall correctly, I find an answer within the first second with ML2

Default avatar.png _Jeffry_: You can run the GA for as long as you can (like 98ms) each turn to get the best possible "first move" every time. Just restart your GA every turn with new starting settings from inputs

Insta-x: so reset GA and use the best first move every turn?

Insta-x: in the blog that i read about solving mars lander with GA, i think that the code solve everything in the first turn and use that solution. though its funny that the blog said the time limit is several seconds

Insta-x: thx for the help

Default avatar.png warsameabdalla: i am really stuck on the chuck norris problem

Default avatar.png warsameabdalla: can somebody check my code i keep getting a bus error

Alshock: Insta-x the blog made everything in the first turn, but you can delay. You can also reause your poppulation from the previous turn in your search, try stuff and keep what works

Alshock: @warsameabdalla you're probably writing something that's out of bound

Alshock: You can dump your code in this chat and it should give you a nice pastebin for it

Insta-x: ok, thx for the tips

Default avatar.png warsameabdalla: http://chat.codingame.com/pastebin/99395a86-6d10-4354-8939-06435f6216b3

Uljahn: the first turn time limit is 1 second btw

Alshock: the best tip I can give you is: look at what your AI is doing. And if it fails to converge or converges too fast, try to find out why. Try to stay calm and tolerant in your fitness though, you don't want to accentuate local minima

Default avatar.png warsameabdalla: thanks Alshock i just posted it

Alshock: xD just a note from first glance warsameabdalla: *(p+t) = 1 + '0' <=> p[t] = '1'

Alshock: not your actual issue though

Default avatar.png warsameabdalla: I literally just got the function from the internet lol

Default avatar.png warsameabdalla: the bus error seems to be coming from this line

Default avatar.png warsameabdalla: char asciiNumber = MESSAGE[j];

Alshock: there's too much I don't understand in your code, for instance, why do you use strtok to split words? I thought CN was about characters

Alshock: Oh mb I was reading commented bits, should get the highlighting in an editor rather than pastebins xD

Default avatar.png warsameabdalla: i am new to this ill try post it without the commented bits

Default avatar.png warsameabdalla: http://chat.codingame.com/pastebin/0c3f257e-1932-4cb0-b6ca-76681cc9118e

Default avatar.png warsameabdalla: i hope this is easier to read

RoboStac: your scanf doesn't do anything (it doesn't support regex and even if it did that still wouldn't match)

Alshock: for some reason, it does. That's what I don't understand.

Default avatar.png warsameabdalla: thanks for that guys the bus error has gone,

Default avatar.png warsameabdalla: however the game came with that scanf("%[^\n]", MESSAGE);

Default avatar.png warsameabdalla: i changed it to this now scanf("%s", MESSAGE);

RoboStac: oh wow, apparently that is actually a thing

Alshock: AH AH AH LMFAO you manage to put stuff in MESSAGE somehow

RoboStac: looks like your str[] array isn't big enough so you overwrite other variables

Alshock: There's a lot of stuff that gets overwritten, j included

Alshock: btw all your decimal_to_binary are leaking memory, but that's a secondary issue at this point)

Default avatar.png warsameabdalla: im really confused lool

Alshock: When I write j and MESSAGE[j] at every step I get this:

Alshock: http://chat.codingame.com/pastebin/c3ac45a0-e59e-4911-8217-0ccd112c2b73

Alshock: That's kinda wrong

Alshock: ooooh I get it

Alshock: the strcat

Alshock: you're not giving a pointer as second param

Alshock: you're actually also writing a pointer in a char to begin with

BlaiseEbuth: Alshock ! Stop annoying people on world ! Go back on FR !

Default avatar.png warsameabdalla: i know ive been asking alot of questions but what shall i change alshock

AntiSquid: why? it's ok, less users on FR more for World

Default avatar.png Tuo: warsameabdalla you are trying to add to str (length 9) multiple return values of decimal_to_binary(length 8?)

Default avatar.png Tuo: also string variable is a char ** for some reason. thats why you need to dereference it, *string in code

2kpro: hey

2kpro: good morning everyone\

tax0801: Hi!

MasterCoderxD: hey guys

MasterCoderxD: help

Default avatar.png Qyxi: Morning. I'm new here. I read the weekly puzzle and I'm not sure I understand the question as the author intended. I look at the possible solutions to the example, and 3 isn't the highest number of nuggets that can not be served. Buying a 5 and a 1 isn't possible, so 6. But even more so, 20 x 5 + 1, infinity * 5 +1 is the highest that can not be served. Since there is not a 1 pack.

MasterCoderxD: Can somebody edit and fix the errors in this Java code?

MasterCoderxD: http://chat.codingame.com/pastebin/35008b02-2922-4c6e-9d8f-f75016874fb3

MasterCoderxD: I am trying to create a range() function, like the one in python3

jacek: Qyxi you can buy 5 and 2. you can buy 6 by buying 3 x 2 nuggets

MasterCoderxD: Just experimenting as i am a noob in Java

jacek: MasterCoderxD there is no default values in java methods

MasterCoderxD: The problem is the part where i set default values for my functional parameters (like in C++)

jacek: use range(int a,int b,int c)

MasterCoderxD: But how do i set default values

Default avatar.png Qyxi: Indeed, overlooked that. So, infinity * 5 + 1 if it's odd becomes the answer.

jacek: the only way to achieve this in java is to overload method

MasterCoderxD: i know i googles it, but i don't quite get it

MasterCoderxD: can u plz just rewrite the code? if u have time?

MasterCoderxD: it's open to everyone btw

linjoehan: I'm need to learn how to write tests in java quick. any helps?

MasterCoderxD: *googled not googles

jacek: http://chat.codingame.com/pastebin/4080e302-cd78-41f1-b838-3223be96e783

jacek: junit tests?

Default avatar.png Tuo: int[] l = new int[b]; is too big. real size is b - a

MasterCoderxD: that works?

jacek: dunno

MasterCoderxD: yeah thanks for that TUO

MasterCoderxD: oh ok

jacek: but should give you idea how this would work

MasterCoderxD: but the problem is with that, it makes it compulsory to enter all the 3 parameters, for example; range(0,10,1) works but not range(10) (this is what i want)

jacek: oh right for one

jacek: http://chat.codingame.com/pastebin/920983f3-32e6-4be6-8a37-fc6e8a893210

MasterCoderxD: my output is:

MasterCoderxD: 9

MasterCoderxD: followed by 9 zeroes

MasterCoderxD: wait i got it

darkhorse64: gg jacek

jacek: hm?

darkhorse64: clobber

jacek: quite lucky submit

jacek: leaderboard small so much oscillations

darkhorse64: You did such a big jump that you surely improve something

jacek: why yes, new net

jacek: and i still think p1 has advantage

jacek: its about 60% win in my tests

ill-be-waiting-outside: hey

darkhorse64: Definitely time to wok on new weapons.

darkhorse64: I have been reading a lot of things lately on NNUE, design and implementation

jacek: :+1:

jacek: well someone got increased speed when he added avx to pragma

darkhorse64: I wrote avx code for clobber with no effect (actually it was slower). I also did that for C4 and gained nothing. But I already got the pragma

darkhorse64: Fun fact, my eval = 57%, your eval = 75% at one point in a game. You won ...

jacek: look for games when i lose

jacek: i get 0.8 then suddenly loss

darkhorse64: I see you won a game where your eval was 0.04 at one point. You have got some bias

jacek: or opponent made mistake

jacek: i know theres something wrong when i evaluate high and lose anyway

darkhorse64: At the same point, I see 50%. Tbh, I sometimes get the impression that my bot is clueless until the solver takes over

jacek: thats vanilla mcts for ya

Default avatar.png Ordonnateur: Hi, can someone explain me more clearly the puzzle of the week ? https://www.codingame.com/ide/puzzle/nuggets-numbers

darkhorse64: yep. No eval in sight and no winning moves for heavy rollouts

jacek: Ordonnateur whats the problem?

Default avatar.png Ordonnateur: I don't understand why the 68 portion part have no maximum ç_ç

Default avatar.png Ordonnateur: 6/8*

Default avatar.png Qyxi: I keep failing first test case. 20 * 5 + 3 = 103 nuggets. That's the max I cannot buy.

darkhorse64: I'd look for diophantian equation of the first degree

jacek: Ordonnateur because you cant buy any odd nuggets. you cant buy 10001, 255545, 5762347856348765348799 and more

jacek: so its infinity

Default avatar.png Qyxi: I agree jacek, however, when I run it it expects 3.

Default avatar.png Ordonnateur: yes but you can't buy 1 or 3 in the first case what's the diff ? the fact there is no stop ?

jacek: 3 is max you cant buy. from 2 and 5 you can buy 4,5,6,7,8,9... and so on

Default avatar.png Qyxi: Ordonnateur 6 and 8 are both even, there can never be an odd number generated from those values.

darkhorse64: Only Chuck Norris can buy any number of nuggets

jacek: Qyxi 17 * 5 + 4 * 2

jacek: wait, 19 * 5

Default avatar.png Ordonnateur: Ok, I have to found how to manage the infinity part (to avoid endless loop) and I think I understand what I should do :)

Default avatar.png Ordonnateur: thank you Jacek :)

2kpro: hello

Default avatar.png kresteodymium: hello

2kpro: how are you

ill-be-waiting-outside: hey

2kpro: yo

ill-be-waiting-outside: whats up my brother

2kpro: nothing much you

ill-be-waiting-outside: working

2kpro: working on what

ill-be-waiting-outside: school and my job

2kpro: im doing in school to

2kpro: virtual

ill-be-waiting-outside: see at my age i have too work in the morning i go to school and at night i work

2kpro: ok

2kpro: well my class started so talk to you later

ill-be-waiting-outside: ight bye

2kpro: bye

evirginie: Hi ! About the weekly puzzle, i really don't see how i can solve it. Could someone give me a hint ? I think maybe a lack a math knowledge.

KelvinAndHubbles: hint: You have to pass all the test cases

evirginie: no wayyyy !

Default avatar.png Snovrain: lmao, although i also dont know how to solve that

evirginie: i thought it must have something to do with GCD but it does not seem to add up

zukarinkuari2: hey guys

2kpro: let ans=[]

zukarinkuari2: i wann acreate a simple game on blender

Default avatar.png Snovrain: actually i am new to codingame, where to access the weekly puzzle?

evirginie: if i just put "print("-1"), i i should past a few tests

zukarinkuari2: bro i cant relate too much

evirginie: here : https://www.codingame.com/ide/puzzle/nuggets-numbers

Default avatar.png Snovrain: tq btw, but what i mean is where can i get this link by myself, from discord?

evirginie: i dont remember how i got here :disappointed_relieved:

evirginie: don't you find it from the home page ?

Default avatar.png Snovrain: yes, my home page dint have something like weekly puzzle section wwww

2kpro: try your best evirginie

2kpro: i made a 36

2kpro: -1

Uljahn: Snovrain: should be in your notifications, click the bell and then "show read"

2kpro: :hamburger: :fries:

Default avatar.png y_ksq: hello

Default avatar.png y_ksq: :wave:

2kpro: hey

2kpro: :wave:

2kpro: im eat so can you keep it down a bit

Default avatar.png ntabucejo: HI

jacek:

2kpro: how do you play code4life

**AntiSquid assumes that's an invisible ball and kicks it

AntiSquid: you don't, life plays you

2kpro: antisquid how do i play code4life

jacek: with joystick

AntiSquid: no joystick, here's a version of the game it's inspired from it should help understand it https://spendee.mattle.online/welcome

AntiSquid: or search on youtube the codingame tutorial for code4life, it explains it well

Default avatar.png warsameabdalla: hello people i have been on chuck norris for 10 hours now

Default avatar.png warsameabdalla: i still can not figure out the issue can someone help me

Default avatar.png warsameabdalla: http://chat.codingame.com/pastebin/91fd84a3-f4f4-45f1-80c0-7e9de74e9d6b

Default avatar.png warsameabdalla: you can ignore the deblank part

Default avatar.png warsameabdalla: anybody there to save the day

jacek: youre doing chuck norris in C? :scream:

AntiSquid: that's so hardcore

AntiSquid: jrke online ?!

jacek: hm?

Therabidpanther: bruh i think this question is broken

2kpro: hahaha:joy:

jacek: question?

Default avatar.png jlb1108: https://ethiery.github.io/codingame/chuck-norris.html

jacek: are those... solutions!?

Default avatar.png jlb1108: yes

Default avatar.png jlb1108: not mine

Default avatar.png jlb1108: still working on mine in C#

Default avatar.png Nihal_me: sup

Default avatar.png Nihal_me: everyone

2kpro: sup

Westicles: hii

2kpro: yo

**AntiSquid kicks Westicles

Westicles: heh heh. I thought you guys made up?

AntiSquid: wdym? it's the special chat command to request a kick

Westicles: Just a kick? That seems like a de-escalation

AntiSquid: what do you want me to do? gather some random people and protest in front of his house at night ?

jacek: oO

BlaiseEbuth: AntiSquid is kicking innocent people again ?

2kpro: what the...

ill-be-waiting-outside: don't say it

jacek: bloody hell

2kpro: ohh sh

jacek: oh bash?

BlaiseEbuth: ./2kpro

2kpro: what

BlaiseEbuth: Unexpected exception...

BlaiseEbuth: Hmmm...

2kpro: can someone hold my mouth before i say something bad

BlaiseEbuth: chmod a+x 2kpro

BlaiseEbuth: ./2kpro

2kpro: shut the fu..

AntiSquid: 2kpro >/dev/null

ill-be-waiting-outside: stop

ill-be-waiting-outside: chill

BlaiseEbuth: Oh thx AntiSquid.

2kpro: im chil

2kpro: :relieved:

Default avatar.png liunique: hey

2kpro: hey

Default avatar.png _Coding_Princess_: hi:stuck_out_tongue_closed_eyes:

2kpro: yo

2kpro: antisquid can you give me some pointers i wish i was experianced like you

jacek: he can give you only nullptr

2kpro: ok thanks for teling me jacek

2kpro: im so stupid i wished i started coding a year or2 ago but im just a child

ZarthaxX: you got a lifetime still

2kpro: but you and other people are experianced and i just started

2kpro: :disappointed:

2kpro: i wish i was older

jacek: just wait and you will be

jacek: [solved]

Default avatar.png _Coding_Princess_: yeah im new too

Default avatar.png _Coding_Princess_: i just finished intro

jacek: onboarding?

2kpro: im just stupid

JLukeSkywalker: no, im stupid

Default avatar.png _Coding_Princess_: im super stupid

Default avatar.png _Coding_Princess_: i am so stupid i cant figure out Coders Strike Back... lol

Default avatar.png _Coding_Princess_: :grimacing:

2kpro: i wished someone like antisquid could give me pointers but his probaly busy

2kpro: :disappointed:

Default avatar.png _Coding_Princess_: yeah

JLukeSkywalker: most people that talk on here can give you pointers like that

2kpro: but antisquid is busy and jonny 7 is busy

JLukeSkywalker: just ask the questions you would ask them in here

2kpro: so who can give me pointers

Stormalix: everyone

JLukeSkywalker: ^^

jacek: int *x; here you go

JLukeSkywalker: how dare you not use python

Default avatar.png YunoSama: Guys.. I really need help with something'

Stormalix: how dare you not use JavaScript

Stormalix: what do u need help with

Default avatar.png YunoSama: I am in the-descent and I don't see the GUI of the mountains nor anything

Default avatar.png YunoSama: In addition to

2kpro: i wished i hade my dad

Default avatar.png YunoSama: I can't print in console

jacek: restart browser

Default avatar.png YunoSama: I mean.. It only shows the goal and notes etc.

Default avatar.png YunoSama: I guess there might be an option somewhere where I view the animation instead ?

2kpro: :sob:

JLukeSkywalker: what puzzle

JLukeSkywalker: can u link the url?

Default avatar.png rip0806: lol

Default avatar.png YunoSama: the-descent

Default avatar.png YunoSama: https://www.codingame.com/ide/puzzle/the-descent

jacek: you should see the viewer normally

Default avatar.png YunoSama: Hm..

JLukeSkywalker: have you hit run?

Default avatar.png YunoSama: Play all testcases? or submit?

JLukeSkywalker: just play the first test case

JLukeSkywalker: does the console pop up?

Default avatar.png YunoSama: It turns green

2kpro: :worried::disappointed::sob: im a piece of trash im nothing but a loser

jacek: can you screenshot?

Default avatar.png YunoSama: Yes.. The console is there but it's totally empty

Default avatar.png YunoSama: Alright one second

Default avatar.png YunoSama: I don't think I can send any pictures here ..

Default avatar.png _Coding_Princess_: 2kpro you are not a loser, nor a piece of trash

jacek: try imgur.com

Default avatar.png YunoSama: omw

Default avatar.png _Coding_Princess_: you are just learning 2kpro

Default avatar.png _Coding_Princess_: nothing to feel bad about

Stormalix: ^

JLukeSkywalker: thought we had a thing on here that captured images like code?

2kpro: :disappointed: ok

2kpro: :worried:

Default avatar.png _Coding_Princess_: :grin:

Default avatar.png _Coding_Princess_: BE HAPPY

2kpro: ok

Default avatar.png ErrorRazor: Lol I just discovered the button that shows the input and expected output of test cases. I've been printing the inputs to error output until now....

Default avatar.png YunoSama: Can I send it in discord instead? It requires registration and I am pretty lazy tbh xD

jacek: so send it to discord

jacek: but imgur doesnt require registration oO

Default avatar.png YunoSama: general ?

Default avatar.png YunoSama: It asked me to register when I tried to add new post :/

2kpro: :relieved:

Default avatar.png _Coding_Princess_: yes

Default avatar.png _Coding_Princess_: good

Default avatar.png YunoSama: It's in general

Default avatar.png _Coding_Princess_: :grin: happy is fun

2kpro: thanks _coding_princess_

2kpro: :relaxed:

Default avatar.png Messi100: Hi

Default avatar.png _Coding_Princess_: :clap_tone1:

Default avatar.png _Coding_Princess_: Hi

Default avatar.png Messi100: how are you doing today

Default avatar.png _Coding_Princess_: Fine, you?

Default avatar.png Messi100: do you know how to code

Default avatar.png Messi100: I am a begginer

Default avatar.png _Coding_Princess_: SAME

Stormalix: try Khan Acadenmy

Stormalix: Academy

Stormalix: its very helpful

Stormalix: i learn JavaScript from KA

Stormalix: learned

Default avatar.png Messi100: thank you man

Stormalix: it was very easy for me to understand

Default avatar.png _Coding_Princess_: i use..... idk

Default avatar.png Messi100: your the best

Default avatar.png _Coding_Princess_: i will brb

2kpro: try code academy not khan academy

Stormalix: if you have any questions u can hmu on KA I'm xXMoonLightXx

Stormalix: nahh KA is better imo

2kpro: are you a youtuber

Default avatar.png Messi100: no

Stormalix: you can take a look at my projects here: https://www.khanacademy.org/profile/xXMoonLightXx/projects

thats how far KA has gotten me so far.. all made in JavaScript

Default avatar.png rip0806: fuck u all

Default avatar.png rip0806: i'm the supreme god

Stormalix: The community is also very helpful so if you have any questions ask anyone

Stormalix: nobody asked rip0906 stfu

2kpro: :joy:

Default avatar.png Messi100: that was grat man

Default avatar.png Messi100: I like at

2kpro: ye

2kpro: me to

Default avatar.png _Coding_Princess_: nobody supreme god rip0906

JLukeSkywalker: the way to learn is totally pick a project you want to do, pick a language, and google the shit out of it

Default avatar.png _Coding_Princess_: and if there was one it would DEFINITELY not be you

JLukeSkywalker: thats how i learn new languages

Default avatar.png Messi100: I will try that idea thank you

Stormalix: JLukeSkywalker For beginners i think its better to have a teacher rather than googling information that may or may not be relevant and may not be the best practive

Stormalix: practice

Default avatar.png _Coding_Princess_: yea

Default avatar.png _Coding_Princess_: practice makes perfect

2kpro: you got that right

Stormalix: practice also makes permanent so dont learn the wrong way xD

Default avatar.png _Coding_Princess_: yes

Default avatar.png _Coding_Princess_: i gtg

Default avatar.png Messi100: do you the YouTuber Mark Rober

Stormalix: yes

Default avatar.png _Coding_Princess_: YES I LOVE HIM

Default avatar.png _Coding_Princess_: he awesome

orangesnowfox: I'd argue practice doesn't really make *perfect* as much as *progress*

Default avatar.png _Coding_Princess_: but i gtg

Default avatar.png _Coding_Princess_: so bye

Stormalix: cya

2kpro: cyu

2kpro: cya

Default avatar.png Messi100: do you know dude perfect fromm youtube

Stormalix: yepp

Stormalix: do u know Mr. Beast

Default avatar.png Messi100: Mrbeast

Stormalix: mrbeast

Stormalix: am i the only one who read that as mr breast

jacek: oO

Yassine_EL_HOSNI: helllo everyone

Yassine_EL_HOSNI: can anyone help with this :

Yassine_EL_HOSNI: the first digit of a really big number using javascript

Yassine_EL_HOSNI: 123**15

Yassine_EL_HOSNI: should be 7

Yassine_EL_HOSNI: any takers ??

AntiSquid: nah i am good

Yassine_EL_HOSNI: naaaa

Default avatar.png ErrorRazor: Can't remember any javascript sorry

PatrickMcGinnisII: 22313961097670283270314823109107

Default avatar.png ErrorRazor: Also it's not 7

Yassine_EL_HOSNI: PatrickMcGinnisII how did you do it

Yassine_EL_HOSNI: it should be rounded up

Default avatar.png ErrorRazor: You mean least significant digit right?

jacek: in python its just 123**15

jacek: i bet there is some mathematical trick to that

jacek: could it be you only need to power the last digit, so its 3**15 ?

Yassine_EL_HOSNI: that would be greate

Yassine_EL_HOSNI: is it

Default avatar.png ErrorRazor: Oh yea

Default avatar.png ErrorRazor: Actually no

N-ONE: @Yessine_EL_HOSNI can you send the problem link ?

Yassine_EL_HOSNI: i dont have it anymore

Yassine_EL_HOSNI: it was a clash of code

N-ONE: oh

Default avatar.png ErrorRazor: Does the calculation time out if you just do 123**15 etc?

Yassine_EL_HOSNI: nop

Default avatar.png ErrorRazor: So what's the problem

Yassine_EL_HOSNI: for me in javascript it shows ...e+31

jacek: https://www.codingame.com/contribute/view/451883b077fe733859abfc66885dff5debc2

Default avatar.png ErrorRazor: Convert to a string, output the last character

N-ONE: http://chat.codingame.com/pastebin/d3f5e317-e25a-45c7-a2b6-4526624da7eb

Yassine_EL_HOSNI: ErrorRazor it did not work in javascript

Yassine_EL_HOSNI: at least for me

N-ONE: any help

Yassine_EL_HOSNI: thank you jacek

jacek: is this puzzle?

Yassine_EL_HOSNI: yap

Default avatar.png ErrorRazor: @Yassine_EL_HOSNI what if you check if the string contains "e", and if it does, take the last digit before e?

Yassine_EL_HOSNI: true

Yassine_EL_HOSNI: but it was a "shortest" mode

Yassine_EL_HOSNI: and my solution was as followed :

Yassine_EL_HOSNI: r=readline,[n,p]=[+r(),+r()] print((n**p)%10)

N-ONE: use mod

Yassine_EL_HOSNI: i did

Yassine_EL_HOSNI: % is mod in javascript

Default avatar.png ErrorRazor: Is there a language in which % is not mod

Yassine_EL_HOSNI: i guess there is

Yassine_EL_HOSNI: 90% sure

jacek: pascal?

Default avatar.png ErrorRazor: Assembly?

Yassine_EL_HOSNI: hhhh guys

Yassine_EL_HOSNI: stop

Yassine_EL_HOSNI: task at hand

jacek: N-ONE well there is O(n) solution for that

N-ONE: hmm really ?

N-ONE: any tips

N-ONE: yassine ,, try computing the power

jacek: i use for loop from n+1 to 2*n

N-ONE: i mean manually

Default avatar.png ErrorRazor: I don't understand the problem

N-ONE: which one ? mine ?

N-ONE: https://www.codingame.com/ide/puzzle/unit-fractions

Default avatar.png ErrorRazor: Ok so it's 1/n

Yassine_EL_HOSNI: NO-ONE i did

Yassine_EL_HOSNI: anyways i give up

Yassine_EL_HOSNI: next clash

Yassine_EL_HOSNI: have fun everyone

N-ONE: i still don't know how did u do it in o(n)

jacek: for i in [...]: if n*i % (i-n) == 0: magic happens

AntiSquid: https://kekpe.pe/i/60637b12cc32a.png

jacek: Oo

N-ONE: yoo @Yassine_EL_HOSNI

N-ONE: check this out

orangesnowfox: jacek, why does everyone use *that* solution?

jacek: is there other no brute-force one?

N-ONE: yes

orangesnowfox: Yeah... `i` is a factor `n^2`

orangesnowfox: *of

jacek: too mathy, do not want

N-ONE: but i don't understand the math lol

orangesnowfox: jacek "i % (n**2 == 0"

orangesnowfox: err, with the closing paren

orangesnowfox: and you go from 1 to n

jacek: syntax error :c

orangesnowfox: well just fix it :p

Default avatar.png ErrorRazor: me no understand

Yassine_EL_HOSNI: hhhhhhhhh

N-ONE: i wonder how to copy code when using vim here ?

Default avatar.png Messi100: hi

Default avatar.png Messi100: can someone tell me how they learn Jave coding please

Yassine_EL_HOSNI: look for a tutorial online, google is your best friend

Default avatar.png Messi100: ok

N-ONE: there is a book called : Object-Oriented Programming and Java

N-ONE: check it out

Default avatar.png Messi100: ok

Yassine_EL_HOSNI: or dont

Default avatar.png Messi100: why

Yassine_EL_HOSNI: books get old

Default avatar.png ErrorRazor: You don't need to buy books, you'll learn best by doing tutorials and projects on your pc

Default avatar.png Messi100: oh ok

N-ONE: it's free i guess ,,, i know it from college lol

Yassine_EL_HOSNI: new thing come up..

Yassine_EL_HOSNI: *things

Yassine_EL_HOSNI: look for "learn java 2020" or "learn java 2021" .. you might get lucky

Default avatar.png Messi100: ok

Yassine_EL_HOSNI: dont forget to have fun

Default avatar.png Messi100: ok

Yassine_EL_HOSNI: and if you have chosen Java as your first language every, you might what to rethink that

Yassine_EL_HOSNI: *ever

Yassine_EL_HOSNI: *want

Yassine_EL_HOSNI: god damn

Default avatar.png Messi100: ok

jacek: kree java!

jacek: AutomatonNN what do you think of java

AutomatonNN: eulerscheZahl is there a way to read the example of a starting point in the middle of a different pl

Default avatar.png Messi100: is khan Academy good

Yassine_EL_HOSNI: no clue

jacek: someone was recommending khan today :thinking:

Yassine_EL_HOSNI: who was it i am guessing

Yassine_EL_HOSNI: was it you??

jacek: no, i dont use any courses

Yassine_EL_HOSNI: naaaa

Yassine_EL_HOSNI: you sure

Yassine_EL_HOSNI: ???

Default avatar.png Messi100: do you know how to use this website In a iPad because my ground want to chat what us so we can answer question for hem

Yassine_EL_HOSNI: i dont understand the question

Yassine_EL_HOSNI: logically i would say "use a mobile browser"

Default avatar.png Messi100: so he can't chat like we do

Yassine_EL_HOSNI: ow i see

Yassine_EL_HOSNI: you mean use the codingame chat ??

Default avatar.png Messi100: so do you know how

Yassine_EL_HOSNI: in mobile

Default avatar.png Messi100: ipad

Yassine_EL_HOSNI: can you download discord on ipad?

Yassine_EL_HOSNI: if so.. and just join the codingame discord

Yassine_EL_HOSNI: this is link

Yassine_EL_HOSNI: i think

Yassine_EL_HOSNI: can someone elaborate?

Yassine_EL_HOSNI: ~and~

Default avatar.png Messi100: do you need a account

Yassine_EL_HOSNI: discord probably not.. but the CodinGame server.. i am guessing it is a must

Stormalix: In my opinion Khan Academy is really good, you can learn HTML and JavaScript from there and the tutorials are very clear (the object oriented tutorial was a bit confusing for me but i understood it on the second run)

Stormalix: There's also a large community willing to help. Its also free sooo why not? lol

0MNIP0TENT: i liked java as my first language. i learned it on a free app called solo learn. i went from that to cloning the classic 2d games within 2months

therealbeef: is it a known bug of CSB that in the first turn you always get -1 as the angle of all pods?

Default avatar.png ErrorRazor: Yeah

Default avatar.png ErrorRazor: It's actually not a bug, you can go any direction on the first turn, after that you'll be limited to an angle that is within 18 degrees of your previous angle

AntiSquid: there was something you could hardcode in that regard, for player 1 and player 2

AntiSquid: for first turn

therealbeef: i think it's a bug because it's a protocol violation

therealbeef: (and search race doesnt have this)

AntiSquid: alright good night

don't let the chat trolls bite

Default avatar.png ErrorRazor: gn

therealbeef: who will ban the kiddies now?

davilla: haha I was a bronze level coding speed yesterday

davilla: today I'm "legend"

Default avatar.png Messi100: Hi do someone know a way to learn Jave programming

davilla: you've come to the right place

hex.master8: https://dontasktoask.com/

_Coding_Princess_: nice website, hex.master8

Default avatar.png CoderScience: Hi I'm new.

Default avatar.png Nagna_Script: wuut up

Default avatar.png Nagna_Script: any ideas on how to double 10$ in 15min ?

Default avatar.png Nagna_Script: on street !!

Default avatar.png Nagna_Script: shoot me with some creativity please ?

Default avatar.png kresteodymium: hi!

Default avatar.png kresteodymium: hello world