troubleshooting Question

"fromCharCode" & "charCodeAt" equivalent functions

Avatar of gavrinas
gavrinas asked on
5 Comments1 Solution1903 ViewsLast Modified:
Suppose we have the following code in JavaScript:

function apokripto()
      var arxiko_string = "wbaof=?,wg=?,wq=?,wbaof=?,wg=?,wq=?,wbaof=?wbaof#`foopsb`jmq>aob`h#tjgwk";
      stringkaki = new String(arxiko_string);  
      var i=0;
      var s="";
      for (i=0; i<stringkaki.length; ++i)  
            s+=String.fromCharCode(stringkaki.charCodeAt(i) ^ 3);

which actually decodes the arxiko_string into s. What I like to know is the exact function of
"String.fromCharCode(stringkaki.charCodeAt(i) ^ 3)"
because the “^3” confuses me. If this is a power of 3, then the value inside the String.fromCharCode might be very high (e.g. 250047 or 85184 or 512000). Are there Unicode characters with so big values?

What I must know is the equivalent function in VB or in excel functions or in just plain mathematics of the “String.fromCharCode(stringkaki.charCodeAt(i) ^ 3)”

Join the community to see this answer!
Join our exclusive community to see this answer & millions of others.
Unlock 1 Answer and 5 Comments.
Join the Community
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 5 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros