【发布时间】:2019-09-13 08:13:52
【问题描述】:
我有一个示例文本,例如“0 zacapa ambar 40% 1l”。我需要帮助来提取此文本的 2 个不同部分。
输出:
1) 萨卡帕安巴尔
2) 40% 1升
例子:
1 smirnoff espresso twist 10l
1 captain morgan black spiced 10l
1 bulleit 95 rye 10l
所以我想只为字符串做一些模糊匹配,并期待在 2 部分中提取细节。
【问题讨论】:
-
提取的逻辑是什么?请在您的问题中添加其他示例(不在 cmets 中),即编辑您的问题:stackoverflow.com/posts/57919736/edit
-
Ex:0942 baileys vanilla cinnamon 100cl 17% 输出:baileys vanilla cinnamon and 100cl 17%
-
将 (1 smirnoff espresso twist 10) 视为一次观察输出:smirnoff espresso twist 和 10 作为单独的输出。因此需要两个不同的输出来存储值请暂时将其模糊匹配