📜  dart touppercase - Dart 代码示例

📅  最后修改于: 2022-03-11 14:48:08.477000             🧑  作者: Mango

代码示例3
import 'dart:io';

main() {
  print("Enter a string : ");
  var str = stdin.readLineSync();

  if (str[0].toUpperCase() == str[0]) {
    print("The first character is uppercase");
  } else {
    print("The first character is not uppercase");
  }
}