/* package whatever; // don't place package name! */

import java.util.*;
import java.lang.*;
import java.io.*;

/* Name of the class has to be "Main" only if the class is public. */
class Ideone
{
	public static void main (String[] args) throws java.lang.Exception
	{
		// declare sting with "%25+ " inside
		String userB = "AAA%25+BBB@DDD.COM";
		System.out.println("plain userB: " +userB);
		System.out.println("URL-encoded userB: " + java.net.URLEncoder.encode(userB, "UTF8") );
		System.out.println("URL-decoded userB: " + java.net.URLDecoder.decode(userB, "UTF8") );

		// declare sting with "% " inside
		String userA = "AAA% BBB@DDD.COM";
		System.out.println("plain userA: " + userA);
		System.out.println("URL-encoded userA: " + java.net.URLEncoder.encode(userA, "UTF8") );
		// DECODING userA raises an runtime-error, 
		// because percent-sign must be followed by a 2-digit number to be valid decodable
		System.out.println("URL-decoded userA: " + java.net.URLDecoder.decode(userA, "UTF8") );

	}
}