Domanda di colloquio di Morgan Stanley

how do you write "2008" at the console using any language without any ?number in your code

Risposte di colloquio

Anonimo

12 mag 2014

We know that C language can work in case of ASCII values so we can use techniques like ASCII values of C-A that will give 2 in numeral,similarly for 0 0 8 also

2

Anonimo

2 ott 2014

Console.WriteLine(('c' - 'a').ToString() + ('a' - 'a').ToString() + ('a' - 'a').ToString() + ('i' - 'a').ToString());

1

Anonimo

15 lug 2014

var today = new Date(); var year = today.getFullYear(); var days = ['sun','mon','tue','wed','thu','fri']; var len = days.length; console.log(year - len);

1