当前位置:网站首页>Write a regular
Write a regular
2022-04-23 17:40:00 【Lost Camel】
demand :
character string : Stock code :002354, Shares referred to as" :*ST Tianyu , Number :2020--119, Bond code :112496, Bond abbreviation :17 Celestial spirit 01, Dalian Tianshen Entertainment Co., Ltd , About “17 Celestial spirit 01" Delisting announcement ,
Required string : Dalian Tianshen Entertainment Co., Ltd
const str = ' Stock code :002354, Shares referred to as" :*ST Tianyu , Number :2020--119, Bond code :112496, Bond abbreviation :17 Celestial spirit 01, Dalian Tianshen Entertainment Co., Ltd , About “17 Celestial spirit 01" Delisting announcement ,'
const info = str.split(/(?<=[:][^,]+),(?=[^,]+[:])/g).map(m=>({ key:m.split(':')[0],value:m.split(':')[1] }))
const compJJ = info.find(m=>m.key ===' Bond abbreviation ')
const compName = compJJ ? compJJ.value.split(',')[1] : ''
console.log(info,compJJ,compName)
// compName To get the company name
版权声明
本文为[Lost Camel]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/04/202204230552420605.html
边栏推荐
- The system cannot be started after AHCI is enabled
- 41. 缺失的第一个正数
- 01-初识sketch-sketch优势
- Qt error: /usr/bin/ld: cannot find -lGL: No such file or directory
- JVM类加载机制
- 开期货,开户云安全还是相信期货公司的软件?
- Why do some people say SCM is simple and I have to learn it so hard?
- Future 用法详解
- Ring back to origin problem - byte jumping high frequency problem
- [binary number] maximum depth of binary tree + maximum depth of n-ary tree
猜你喜欢

JVM class loading mechanism

超分之TDAN

470. Rand10() is implemented with rand7()

STM32 entry development board choose wildfire or punctual atom?

Summary of common SQL statements

Qt error: /usr/bin/ld: cannot find -lGL: No such file or directory

2021长城杯WP
Compare the performance of query based on the number of paging data that meet the query conditions

常用SQL语句总结

Double pointer advanced -- leetcode title -- container with the most water
随机推荐
[simple understanding of database]
给 el-dialog 增加拖拽功能
402. 移掉 K 位数字-贪心
Learning record of uni app dark horse yougou project (Part 2)
Simulation of infrared wireless communication based on 51 single chip microcomputer
[batch change MySQL table and corresponding codes of fields in the table]
Halo open source project learning (II): entity classes and data tables
Compare the performance of query based on the number of paging data that meet the query conditions
node中,如何手动实现触发垃圾回收机制
为什么有些人说单片机简单,我学起来这么吃力?
Flash project cross domain interception and DBM database learning [Baotou cultural and creative website development]
Self use learning notes - connectingstring configuration
Model problems of stock in and stock out and inventory system
Summary of common SQL statements
Double pointer advanced -- leetcode title -- container with the most water
MySQL进阶之索引【分类,性能分析,使用,设计原则】
Qt error: /usr/bin/ld: cannot find -lGL: No such file or directory
Manually implement simple promise and its basic functions
How does matlab draw the curve of known formula and how does excel draw the function curve image?
JVM类加载机制