本文介绍了谁能为我写一个正则表达式。的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一些数据需要处理。





数据:



{face:603,flag:285786694,nick:陈德兴,uin:906516573},

{face:9,flag: 17302022,nick:拉丁香烟,uin:99689067},

{face:0,flag:289948238,nick:冰血封情, uin:1838638686},

{face:654,flag:512,nick:NIU,uin:1019680323}

{face:603,flag:294126146,nick:̶4̶1̶9̶5̶8̶1̶3̶,uin:1678381076},





我想使用正则表达式来获取缺口和uin。





输出:



陈德兴906516573

拉丁香烟99689067

冰血封情1838638686

NIU 1019680323
$ b $b4̶1̶9̶5̶8̶1̶3̶1678381076





谁可以为我写一个正则表达式来处理这些数据。

I have some data to deal with .


data:

{"face":603,"flag":285786694,"nick":"陈德兴","uin":906516573},
{"face":9,"flag":17302022,"nick":" 拉丁香烟","uin":99689067},
{"face":0,"flag":289948238,"nick":"冰血封情","uin":1838638686},
{"face":654,"flag":512,"nick":"NIU","uin":1019680323}
{"face":603,"flag":294126146,"nick":"̶4̶1̶9̶5̶8̶1̶3̶","uin":1678381076},


I want to use regular expression to get the "nick" and "uin" out .


output:

陈德兴 906516573
拉丁香烟 99689067
冰血封情 1838638686
NIU 1019680323
4̶1̶9̶5̶8̶1̶3̶ 1678381076


Who can write a regular expression for me to deal this data .

推荐答案

(?<="nick":")(?<Nick>.*?)(?:","uin":)(?<Uin>\d+)



获取的副本[] - 它是免费的,它会检查并生成正则表达式。



HTML编码 - OriginalGriff [/ edit]


Get a copy of Expresso [^] - it''s free, and it examines and generates Regular expressions.

[edit]HTML Encoded - OriginalGriff[/edit]


这篇关于谁能为我写一个正则表达式。的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

09-17 22:25