• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

How do I make a project that encrypts and decrypts a word the user inputs?

 
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I am using Eclipse, so I don't need any code for the ASCII.

I need to create a project that encrypts and decrypts whatever the user inputted. Here is the code I wrote:


 
author
Posts: 23951
142
jQuery Eclipse IDE Firefox Browser VI Editor C++ Chrome Java Linux Windows
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Natasha Morehouse wrote:I am using Eclipse, so I don't need any code for the ASCII.



Huh ?!?!?!?
 
Natasha Morehouse
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Henry Wong wrote:

Natasha Morehouse wrote:I am using Eclipse, so I don't need any code for the ASCII.



Huh ?!?!?!?



Eclipse already knows the ASCII (I don't know if you need code for it or not, my teacher didn't explain ASCII very well)
 
Henry Wong
author
Posts: 23951
142
jQuery Eclipse IDE Firefox Browser VI Editor C++ Chrome Java Linux Windows
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Natasha Morehouse wrote:Eclipse already knows the ASCII (I don't know if you need code for it or not, my teacher didn't explain ASCII very well)



Java uses the unicode standard for characters. Unicode is a super set of ASCII, so Java supports ASCII.... Eclipse (the Integrated Development Environment) doesn't need to do anything special to support Java regarding this.

Henry
 
Henry Wong
author
Posts: 23951
142
jQuery Eclipse IDE Firefox Browser VI Editor C++ Chrome Java Linux Windows
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Natasha Morehouse wrote:Here is the code I wrote:



Have you compiled this code? The section above isn't valid Java code.

Henry
 
Natasha Morehouse
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I know, I'm attempting to fix that right now (I kind of suck at programming)
 
Henry Wong
author
Posts: 23951
142
jQuery Eclipse IDE Firefox Browser VI Editor C++ Chrome Java Linux Windows
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Natasha Morehouse wrote:I know, I'm attempting to fix that right now (I kind of suck at programming)



A couple of recommendations that may help... First, when using pseudo code (not real code), it may be a good idea to "comment" them -- meaning prefix those lines with "//". This way, you can still compile the partially completed code. Second, no need to invent a new language for pseudo code, writing it using java syntax mixed with english is probably best -- but this is your decision, whatever is easier. Also, eclipse support the TODO tag in comments. When you add this tag, eclipse will highlight them in a different color, and lists them in one of the subwindows. Basically, eclipse is keeping a TODO list for you.

Henry
 
Natasha Morehouse
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Henry Wong wrote:

A couple of recommendations that may help... First, when using pseudo code (not real code), it may be a good idea to "comment" them -- meaning prefix those lines with "//". This way, you can still compile the partially completed code. Second, no need to invent a new language for pseudo code, writing it using java syntax mixed with english is probably best -- but this is your decision, whatever is easier. Also, eclipse support the TODO tag in comments. When you add this tag, eclipse will highlight them in a different color, and lists them in one of the subwindows. Basically, eclipse is keeping a TODO list for you.

Henry



Thanks I'll try to do that, but I am having trouble on figuring out how to make it so the word's ASCII will change when encrypted and will be the same word when decrypted
reply
    Bookmark Topic Watch Topic
  • New Topic