这个问题已经有了答案:
在初始用户提示后寻找删除电子邮件地址“@domain”的好方法。
prompt = input("Enter the email address of the user: ")
所有的域都是相同的,所以我不需要担心子域或任何其他的奇怪。
输入:john.doe@generic.com 输出:john.doe
我希望输出进入另一个变量,以便在Linux服务器上的一系列bash命令中使用。