import java.util.*;

public class Solution{
	public static void main(String[] args){
		Scanner in = new Scanner(System.in);
		int numberOfTestCases = Integer.parseInt(in.nextLine());
        for (int i = 0; i< numberOfTestCases; i++) {
			String line = in.nextLine();
            printContentEnclosedWithinTags(line);
		}
        in.close();
	}

    public static void printContentEnclosedWithinTags(String line) {
        System.out.println("Foo");
        // Regex
        // <([\w\d\s]+)>([\w\d\s]+)(<\/\1>)
    }
}

@@ -12,16 +12,80 @@
 .util.*;
+%0Aimport java.util.regex.Matcher;%0Aimport java.util.regex.Pattern;
 %0A%0Apublic
@@ -484,95 +484,353 @@
     
-System.out.println(%22Foo%22);%0A        // Regex%0A        // %3C(%5B%5Cw%5Cd%5Cs%5D+)%3E(%5B%5Cw%5Cd%5Cs%5D+)(%3C%5C/%5C1%3E)
+Pattern pattern = Pattern.compile(%22%3C(.+)%3E(%5B%5E%3C%5D+)%3C/%5C%5C1%3E%22);%0A        Matcher matcher = pattern.matcher(line);%0A        boolean matchFound = false;%0A%0A        while (matcher.find()) %7B%0A            System.out.println(matcher.group(2));%0A            matchFound = true;%0A        %7D%0A%0A        if (!matchFound) %7B%0A            System.out.println(%22None%22);%0A        %7D
 %0A   

Solve tag content extractor