#include <bits/stdc++.h>
using namespace std;
int main() {
  int tc;
  cin >> tc;
  while (tc--) {
    string s;
    cin >> s;
    string ss = "";
    set<char> ch;
    for (int i = 0; i < s.size(); i++) {
      ch.insert(s[i]);
    }
    if ((ch.size() != s.size()) || s.size() == 1) {
      if (s.size() == 1) {
        cout << "Yes" << endl;
      } else
        cout << "No" << endl;
    } else {
      int index = 0;
      int ary[s.size()];
      for (int i = 0; i < s.size(); i++) {
        int ll = s[i] - '0';
        ary[index++] = ll;
      }
      sort(ary, ary + s.size());
      for (int i = 0; i < s.size(); i++) {
        for (int j = 0; j < s.size(); j++) {
          if (ary[i] == (s[j] - '0')) {
            ss += s[j];
          }
        }
      }
      bool flag = true;
      for (int i = 0; i < ss.size() - 1; i++) {
        int nextindex = i;
        if (((ss[++nextindex] - '0') - (ss[i] - '0')) != 1) {
          flag = false;
          break;
        }
      }
      if (flag) {
        cout << "Yes" << endl;
      } else {
        cout << "No" << endl;
      }
      ch.clear();
    }
  }
  return 0;
}
