三大模型对比 Hunyuan DeepSeek Doubao

试题是这样的


You have a list with website URLs with some mistakes — capital letters. Print the number of the list elements, fix the mistakes in each element of this list, make a map with the domains as key and the length of the respective URLs as value. Try to do it within the body of a proper scope function.
Note: Don’t print the whole map, only return it.

Sample Input 1:

1
htTpS://hypeRskIll.org HTTPS://www.jetbrains.com https://github.com

Sample Output 1:

1
2
3
{https://hyperskill.org=22, https://www.jetbrains.com=25, https://github.com=18}

Write a program in Kotlin

1
2
3
fun filterAndMatch() : Map<String, Int>{
//write your code here
}

在【腾讯元宝】使用Hunyuan

腾讯元宝

在【豆包】直接使用AI编程

豆包

在【腾讯元宝】使用DeepSeek

腾讯元宝

最终选择

从答案的简洁上我会选择豆包给的答案,【腾讯元宝】Hunyuan模型给的答案,我个人不会采用,有点罗嗦,而且不符合出题的意思,【腾讯元宝】DeepSeek模型给的答案,比较周全,比如多了一个filter

最主要的问题【腾讯元宝】Hunyuan模型似乎没有理解题目的意思

从题目看第一步需要获取输入的内容,Hunyuan就创建了一个变量,这一点看出并没有理解题目的意思