gpt4 book ai didi

android - 如何在大消息中搜索确切的词?

转载 作者:行者123 更新时间:2023-11-29 15:18:38 25 4
gpt4 key购买 nike

如何在Android中搜索一条大消息中的一个词?

我有一个文本,如“太阳总是照耀在云层之上”。我想搜索一个词,例如“太阳”,并将其更改为图像。这个怎么做?有什么办法吗?

最佳答案

String word = "cat";
String text = "The cat is on the table";
Boolean found;

found = text.contains(word);

关于android - 如何在大消息中搜索确切的词?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/21173562/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com