Skip to main content
added 2 characters in body
Source Link
M--
  • 1.3k
  • 8
  • 16

R, 3435 bytes

\(x)grepl("\\bIll([^aiou]|$[^aiouy]|$)",x,T)

Attempt This Online!Attempt This Online!

grepl(
  "            
  \\b          # a word boundary
  Ill          # followed by "Ill"
  ([^aiou]|$[^aiouy]|$)  # followed by either a non-aiouaiouy character OR end of string"
  "  
  x,           
  T            # ignore.case = TRUE
)

Obviously we could port the same pattern used in JS answers:

R, 3536 bytes

\(x)grepl("\\bIll(?![aiou][aiouy])",x,T,T)

Attempt This Online!Attempt This Online!

R, 34 bytes

\(x)grepl("\\bIll([^aiou]|$)",x,T)

Attempt This Online!

grepl(
  "            
  \\b          # a word boundary
  Ill          # followed by "Ill"
  ([^aiou]|$)  # followed by either a non-aiou character OR end of string"
  "  
  x,           
  T            # ignore.case = TRUE
)

Obviously we could port the same pattern used in JS answers:

R, 35 bytes

\(x)grepl("\\bIll(?![aiou])",x,T,T)

Attempt This Online!

R, 35 bytes

\(x)grepl("\\bIll([^aiouy]|$)",x,T)

Attempt This Online!

grepl(
  "            
  \\b          # a word boundary
  Ill          # followed by "Ill"
  ([^aiouy]|$)  # followed by either a non-aiouy character OR end of string"
  "  
  x,           
  T            # ignore.case = TRUE
)

Obviously we could port the same pattern used in JS answers:

R, 36 bytes

\(x)grepl("\\bIll(?![aiouy])",x,T,T)

Attempt This Online!

deleted 39 characters in body
Source Link
M--
  • 1.3k
  • 8
  • 16

Obviously I can port the pattern used in JS answers like this:

R, 35 bytes

\(x)grepl("\\bIll(?![aiou])",x,T,T)

Attempt This Online!


But a bit different would be:

R, 34 bytes

\(x)grepl("\\bIll([^aiou]|$)",x,T)

Attempt This Online!

grepl(
  "            
  \\b          # a word boundary
  Ill          # followed by "Ill"
  ([^aiou]|$)  # followed by either a non-aiou character OR end of string"
  "  
  x,           
  T            # ignore.case = TRUE
)

Obviously we could port the same pattern used in JS answers:

R, 35 bytes

\(x)grepl("\\bIll(?![aiou])",x,T,T)

Attempt This Online!

Obviously I can port the pattern used in JS answers like this:

R, 35 bytes

\(x)grepl("\\bIll(?![aiou])",x,T,T)

Attempt This Online!


But a bit different would be:

R, 34 bytes

\(x)grepl("\\bIll([^aiou]|$)",x,T)

Attempt This Online!

grepl(
  "            
  \\b          # a word boundary
  Ill          # followed by "Ill"
  ([^aiou]|$)  # followed by either a non-aiou character OR end of string"
  "  
  x,           
  T            # ignore.case = TRUE
)

R, 34 bytes

\(x)grepl("\\bIll([^aiou]|$)",x,T)

Attempt This Online!

grepl(
  "            
  \\b          # a word boundary
  Ill          # followed by "Ill"
  ([^aiou]|$)  # followed by either a non-aiou character OR end of string"
  "  
  x,           
  T            # ignore.case = TRUE
)

Obviously we could port the same pattern used in JS answers:

R, 35 bytes

\(x)grepl("\\bIll(?![aiou])",x,T,T)

Attempt This Online!

Source Link
M--
  • 1.3k
  • 8
  • 16

Obviously I can port the pattern used in JS answers like this:

R, 35 bytes

\(x)grepl("\\bIll(?![aiou])",x,T,T)

Attempt This Online!


But a bit different would be:

R, 34 bytes

\(x)grepl("\\bIll([^aiou]|$)",x,T)

Attempt This Online!

grepl(
  "            
  \\b          # a word boundary
  Ill          # followed by "Ill"
  ([^aiou]|$)  # followed by either a non-aiou character OR end of string"
  "  
  x,           
  T            # ignore.case = TRUE
)