作者:戴耳机聆听世界 | 来源:互联网 | 2023-10-10 06:29
I have a program that takes data from a file:
我有一个从文件中获取数据的程序:
Id First Name Last Name
1 John Smith
2 Joe Blow
3 Cat Dog
Then takes that data and generates a username and password based on the info given above:
然后获取该数据并根据上面给出的信息生成用户名和密码:
Id Username Password
1 SmJo1 w6o3ju2y
2 BlJo2 kv4nbu4a
3 DoCa3 7gpxlaup
Basically what I need done is to get my program to organize the input file in alphabetical order according to last name which would in turn organize my output file in the same order, I have no idea how to go about this though.
基本上我需要做的是让我的程序按照字母顺序按照字母顺序组织输入文件,而后者又按照相同的顺序组织我的输出文件,我不知道如何去做。
4 个解决方案