Percentage command Problem

Asked Oct 26, 2020·2 replies·Last activity 5 years ago·Open in Discord ↗
Archived from the original community forum
Things may have changed since it was written. Still stuck? Ask the community on Discord.

I keep getting an unexpected identifier don't know where the problem is

If i remove both >" " the code works perfectly but i wanted to work with the both " "

$(eval random=Math.floor((Math.random()*100)+1); var randomPercent=random+"% ";random>=65?randomPercent+"Message1":randomPercent+", in the words of Albert Einstein "imagination is more important then knowledge" ")

2 replies

@Tidy Snail Heya, use `" "`` ( backtick ) instead of any other quotation mark.

``$(eval random=Math.floor((Math.random()*100)+1); var randomPercent = random + % ; random >= 65 ? randomPercent + Message1 : randomPercent + , in the words of Albert Einstein "imagination is more important then knowledge")``

Hope it will work.