#include <bits/stdc++.h>
using namespace std;
const int N = 5e5 + 20, M = 3e5 + 20;
bool isprime[N];
long long fastexp(long long a, long long b) {
  long long res = 1;
  while (b > 0) {
    if (b & 1) {
      res = (res * a);
    }
    a = (a * a);
    b = b >> 1;
  }
  return res;
}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  char s[N];
  gets(s);
  long long n = strlen(s);
  for (long long i = 0; i < n; i++) {
    if (s[i] == '"') {
      putchar('<');
      for (i++; s[i] != '"' && i < n; i++) putchar(s[i]);
      puts(">");
    } else if (s[i] != ' ') {
      putchar('<');
      for (; s[i] != ' ' && i < n; i++) putchar(s[i]);
      puts(">");
    }
  }
}
