How JustAnswer Works:

  • Ask an Expert
    Experts are full of valuable knowledge and are ready to help with any question. Credentials confirmed by a Fortune 500 verification firm.
  • Get a Professional Answer
    Via email, text message, or notification as you wait on our site.
    Ask follow up questions if you need to.
  • 100% Satisfaction Guarantee
    Rate the answer you receive.

Ask LogicPro Your Own Question

LogicPro
LogicPro, Engineer
Category: Homework
Satisfied Customers: 9967
Experience:  Expert in Java C++ C C# VB Javascript Design SQL HTML
29751445
Type Your Homework Question Here...
LogicPro is online now
A new question is answered every 9 seconds

For LogicPro only For LogicPro only Refer to the Java

Customer Question

For LogicPro only

For LogicPro only

Refer to the Java Coding Style Document.
Add comments as required for all .java files

Provide a complete program that performs a simple substitution cipher. The program should take plain text and a shift value and produce the encrypted text. Then it should take encrypted text and a shift value and produce the plain text once again. A different encrypted text and shift can be entered so make sure to get input.

Example:
EASTER shifted by 3 to left would become HDVWHU
HDVWHU shifted by 3 to right would become EASTER

This is how the early Caesar Cipher worked.

Provide a main method. It should:

Get input for a string and a shift value
Convert to upper case
Only perform the following items on alphabetic characters between A and Z
Utilize a for loop which uses postfix incrementing operator
Convert character to its ASCII equivalent (type cast)
Shift buy shift value entered above
If you reach end of alphabet, wrap around
Example: A shifted to the left 2 would become Y
Convert back to its character equivalent (type cast)
Output the new character
Get input for a string and a shift value
Perform same steps above to convert the encrypted text back to plain text
Be sure to get input again as a different encrypted text may be entered
Utilize postfix increment/decrement operations and compound assignment operators for all math. Example: x++ or x+=2.

Sample Session:

Please enter text to encrypt
easter
Please enter shift value
3
BXPQBO
Please enter text to decrypt
bxpqbo
Please enter shift value
-3
EASTER
Press any key to continue . . .
Submitted: 1 year ago.
Category: Homework
Expert:  LogicPro replied 1 year ago.
Hi,
Welcome back and thank you for asking me.
What is the deadline for this?
Customer: replied 1 year ago.

No problem you provide great answers and i haven't had one issue with getting them by the time we agree upon.


 


The deadline for this assignment is Saturday, but hoping to have it by Friday evening

Expert:  LogicPro replied 1 year ago.
These are a lot and will take time. I am sending an email indicating new and fair price for this question. You may increase the price of the question. Please check inbox/spam/junk folder of the email address registered with JustAnswer and let me know.
Customer: replied 1 year ago.

roger that, just increased it 5$

Expert:  LogicPro replied 1 year ago.
Have you checked the under priced email?
Updated price is not as per the email.
Customer: replied 1 year ago.

Oh i thought that was an example, i can't afford that much for it !

Expert:  LogicPro replied 1 year ago.
I can do it for $40, please let me know or I should opt out for other experts to join you.

Customer: replied 1 year ago.

I could do it for 30$ but i think that's the max i can afford due to limited funds from vacation.

Expert:  LogicPro replied 1 year ago.
ok, I will do it for you.
I will provide you answer ASAP.
Customer: replied 1 year ago.

ok sounds good

Expert:  LogicPro replied 1 year ago.
:)
Expert:  LogicPro replied 1 year ago.
THIS ANSWER IS LOCKED!
You can view this answer by clicking here to Register or Login and paying $3.
If you've already paid for this answer, simply Login.
LogicPro, Engineer
Category: Homework
Satisfied Customers: 9967
Experience: Expert in Java C++ C C# VB Javascript Design SQL HTML
LogicPro and other Homework Specialists are ready to help you
Customer: replied 1 year ago.

Most of the code worked well, but i wasn't generating these results in the sample


 


Sample Session:

Please enter text to encrypt
easter
Please enter shift value
3
BXPQBO
Please enter text to decrypt
bxpqbo
Please enter shift value
-3
EASTER
Press any key to continue . . .


Sample Session 2: : (Notice spaces removed from input)

Please enter text to encrypt
This Is A Test
Please enter shift value
3
QEFPFPXQBPQ
Please enter text to decrypt
qefpfpxqbpq
Please enter shift value
-3
THISISATEST
Press any key to continue . . .


 


All the inputs worked properly, but for example in the first scenario it wasn't printing out BXPQBO / bxpqbo but everything else worked fine


 

Expert:  LogicPro replied 1 year ago.
I will review and reply ASAP.
Customer: replied 1 year ago.

sounds good, no super rush as long as i get it by tomorrow evening i should be good. Thanks Sir

Expert:  LogicPro replied 1 year ago.
welcome
Customer: replied 1 year ago.

Didn't hear anything back from ya yet, it compiled and work properly, it just left those weird characters out. I'm not even sure why they're supposed to be there. I may just submit it the way it is. Should get a good enough grade for it since it does work right.

Customer: replied 1 year ago.

:)

Expert:  LogicPro replied 1 year ago.
Thanks :)

JustAnswer in the News:

 
 
 
Ask-a-doc Web sites: If you've got a quick question, you can try to get an answer from sites that say they have various specialists on hand to give quick answers... Justanswer.com.
JustAnswer.com...has seen a spike since October in legal questions from readers about layoffs, unemployment and severance.
Web sites like justanswer.com/legal
...leave nothing to chance.
Traffic on JustAnswer rose 14 percent...and had nearly 400,000 page views in 30 days...inquiries related to stress, high blood pressure, drinking and heart pain jumped 33 percent.
Tory Johnson, GMA Workplace Contributor, discusses work-from-home jobs, such as JustAnswer in which verified Experts answer people’s questions.
I will tell you that...the things you have to go through to be an Expert are quite rigorous.
 
 
 

What Customers are Saying:

 
 
 
  • Wonderful service, prompt, efficient, and accurate. Couldn't have asked for more. I cannot thank you enough for your help. Mary C. Freshfield, Liverpool, UK
< Last | Next >
  • Wonderful service, prompt, efficient, and accurate. Couldn't have asked for more. I cannot thank you enough for your help. Mary C. Freshfield, Liverpool, UK
  • This expert is wonderful. They truly know what they are talking about, and they actually care about you. They really helped put my nerves at ease. Thank you so much!!!! Alex Los Angeles, CA
  • Thank you for all your help. It is nice to know that this service is here for people like myself, who need answers fast and are not sure who to consult. GP Hesperia, CA
  • I couldn't be more satisfied! This is the site I will always come to when I need a second opinion. Justin Kernersville, NC
  • Just let me say that this encounter has been entirely professional and most helpful. I liked that I could ask additional questions and get answered in a very short turn around. Esther Woodstock, NY
  • Thank you so much for taking your time and knowledge to support my concerns. Not only did you answer my questions, you even took it a step further with replying with more pertinent information I needed to know. Robin Elkton, Maryland
  • He answered my question promptly and gave me accurate, detailed information. If all of your experts are half as good, you have a great thing going here. Diane Dallas, TX
 
 
 

Meet The Experts:

 
 
 
  • Manal Elkhoshkhany

    Tutor

    Satisfied Customers:

    4522
    More than 5000 online tutoring sessions.
< Last | Next >
  • http://ww2.justanswer.com/uploads/BU/BusinessTutor/2012-2-2_115741_Kouki2.64x64.jpg Manal Elkhoshkhany's Avatar

    Manal Elkhoshkhany

    Tutor

    Satisfied Customers:

    4522
    More than 5000 online tutoring sessions.
  • http://ww2.justanswer.com/uploads/ComputersGuru/2010-02-13_051118_Photo41.JPG LogicPro's Avatar

    LogicPro

    Engineer

    Satisfied Customers:

    3458
    Expert in Java C++ C C# VB Javascript Design SQL HTML
  • http://ww2.justanswer.com/uploads/LI/lindaus/2012-6-10_04811_IMG20120609164157.64x64.jpg Linda_us's Avatar

    Linda_us

    Finance, Accounts & Homework Tutor

    Satisfied Customers:

    3124
    Post Graduate Diploma in Management (MBA)
  • http://ww2.justanswer.com/uploads/chooser77/2009-08-18_162025_Chris.jpg Chris M.'s Avatar

    Chris M.

    M.S.W. Social Work

    Satisfied Customers:

    2385
    Master's Degree, strong math and writing skills, experience in one-on-one tutoring (college English)
  • http://ww2.justanswer.com/uploads/JawaadAhmed/2009-6-27_12137_SIs_SHadi.jpg F. Naz's Avatar

    F. Naz

    Chartered Accountant

    Satisfied Customers:

    1988
    Experience with chartered accountancy
  • http://ww2.justanswer.com/uploads/JK/jkcpa/2011-1-16_182614_jkcpa.64x64.jpg Bizhelp's Avatar

    Bizhelp

    CPA

    Satisfied Customers:

    1876
    Bachelors Degree and CPA with Accounting work experience
  • http://ww2.justanswer.com/uploads/avremote/photoa.jpg Seanna's Avatar

    Seanna

    Tutor

    Satisfied Customers:

    1781
    3,000+ satisfied customers, all topics, A+ work
 
 
 
Chat Now With A Tutor
LogicPro
LogicPro
3728 Satisfied Customers
Expert in Java C++ C C# VB Javascript Design SQL HTML