I guarantee you, any crypto scheme that you build from scratch WILL be incredibly vulnerable to many, many different, widely known attacks. Crypto schemes depend on some very heavy mathematics, and as Carnage said, unless you have a doctorate in mathematics and/or crypto, stick to the existing, proven algorithms.
I've been watching lectures from a bachelor's program out of Germany, put out by the University of Bochum, and the instructor has given example after example of schemes his former students have put together that utterly fail when tested against some fairly simple attacks, and these are college grads.
But to answer your original question, the absolute most fundamental part of many encryption schemes is the Xor operator (or Modulo 2, for math gurus).
XOR-ing your data with a 'key' that you pick is a very simple "encryption" method. I say 'encryption' in quotes, because it's more of an obfuscation step than it is encryption. It provides virtually no cryptographic strength, but it does obscure the plaintext to anyone who's not determined enough to decrypt the ciphertext, which is relatively easy in this scheme.
I have a project on my
Github page that does exactly this, if you'd like to take a look at it.