Skip to content

Instantly share code, notes, and snippets.

@DeclanGas
Created June 23, 2022 16:43
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save DeclanGas/bd89d06423cf2099b3e4b56ffff8fc37 to your computer and use it in GitHub Desktop.
Save DeclanGas/bd89d06423cf2099b3e4b56ffff8fc37 to your computer and use it in GitHub Desktop.
#include <cs50.h>
#include <stdio.h>
#include <string.h>
int main(void)
{
// get a string named plaintext
string plaintext = get_string("plaintext: ");
// output the string
for (int i = 0; i < strlen(plaintext); i++)
{
printf("%c", plaintext[i] + 1);
}
printf("\n");
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment