Search:

Type: Posts; User: forms

Search: Search took 0.20 seconds.

  1. Replies
    16
    Views
    2,639

    Re: java ceaser cipher stanford lectures

    Hi, i had another question.

    from the code extract below why cant i keep the parameters in the encrypt method as
    private String encrypt(String word, int key)

    Why do i have to use a new...
  2. Replies
    16
    Views
    2,639

    Re: java ceaser cipher stanford lectures

    thanks for your help
  3. Replies
    16
    Views
    2,639

    Re: java ceaser cipher stanford lectures

    I thought these two lines of code were needed when a user inputs a negative number but when i comment out these two lines and input a negative value it works fine.

    With these two lines included it...
  4. Replies
    16
    Views
    2,639

    Re: java ceaser cipher stanford lectures

    That makes sense, thanks for explaining that.

    Also when i comment out these two lines from the main method the program works fine. Can you see why these lines of code are included in the program?...
  5. Replies
    16
    Views
    2,639

    Re: java ceaser cipher stanford lectures

    Thanks for that it worked.
    Also why did i need to write ceaser s = new ceaser(); and write s.encrypt?
    I know this is a stupid question but i dont really get it. When i write static in the methods...
  6. Replies
    16
    Views
    2,639

    Re: java ceaser cipher stanford lectures

    You are right when i enter the number and word on the same line it will output the encoded word
    So what should i add to change this?
    Thanks for your help by the way.
  7. Replies
    16
    Views
    2,639

    Re: java ceaser cipher stanford lectures

    It doesnt let me enter a word.
    It just lets me enter a digit, then it outputs the last two lines.
    Im not really sure why this doesnt work as i copied it exactly from the youtube video
    I noticed i...
  8. Replies
    16
    Views
    2,639

    Re: java ceaser cipher stanford lectures

    the output is below. I typed 2.
    ____________________
    Enter a ceaser cipher:
    2
    Enter word to encode:
    Encoded text:
    new word:
    _________________

    The program will ask for a number, and then...
  9. Replies
    16
    Views
    2,639

    java ceaser cipher stanford lectures

    Hi,

    i am working through some java stanford tutorials on youtube and i copied out some code from ep 13 from the lecture but cant get it to work.

    My code doesnt work correctly. It just prints...
Results 1 to 9 of 9