#include <bits/stdc++.h>
using namespace std;
char s = '/';
int main() {
  string a, b = "";
  cin >> a;
  cout << '/';
  char p = '/';
  for (int i = 0; i < a.size(); i++) {
    if (p == s && a[i] == s)
      continue;
    else {
      p = a[i];
      b += a[i];
    }
  }
  if (b[b.size() - 1] == s) {
    string tmp = "";
    int ptr = b.size() - 5;
    if (ptr >= 0) {
      tmp += b[ptr];
      tmp += b[ptr + 1];
      tmp += b[ptr + 2];
      tmp += b[ptr + 3];
      if (tmp != "root") b.resize(b.size() - 1);
    } else
      b.resize(b.size() - 1);
  } else {
    string tmp = "";
    int ptr = b.size() - 4;
    if (ptr >= 0) {
      tmp += b[ptr];
      tmp += b[ptr + 1];
      tmp += b[ptr + 2];
      tmp += b[ptr + 3];
      if (tmp == "root") b += '/';
    }
  }
  cout << b << endl;
  return 0;
}
