Thanks Henry, that’s great! Thanks also to other contributors. Sent from Mail<https://go.microsoft.com/fwlink/?LinkId=550986> for Windows
________________________________ From: Programming <programming-boun...@forums.jsoftware.com> on behalf of Henry Rich <henryhr...@gmail.com> Sent: Friday, April 8, 2022 3:32:45 PM To: programm...@jsoftware.com <programm...@jsoftware.com> Subject: Re: [Jprogramming] Help required l =. 'abc','def',:'ghi' l abc def ghi r =. 'abceee','defabc','mmmxxx','abcdef',:'ghidef' r abceee defabc mmmxxx abcdef ghidef l (] #~ [: *./"1 (e.~ 2 3&$"1)) r defabc abcdef ghidef Henry Rich On 4/8/2022 10:21 AM, Richard Donovan wrote: > Hi J programmers > > I need help to discover the most efficient way of doing the following :- > > I have two tables, on of n three-character items, and a second of m > six-character items such as… > > abc,def,ghi > > abceee,defabc,mmmxxx,abcdef,ghidef > > I need to know which six-character items can be composed of any two > concatenated three-character items, so in the above example the required > output would be > > defabc,abcdef,ghidef > > There may be many thousands of entries in each tables, so an efficient > algorithm is required! > > Thanks in advance > > Richard Donovan > > ---------------------------------------------------------------------- > For information about J forums see http://www.jsoftware.com/forums.htm -- This email has been checked for viruses by AVG. https://www.avg.com ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm