String Pattern to match “x by y”

I’m trying to create a string pattern which will match either (with quotes included):

  • “x by y”
  • x by y
  • ‘x by y’

I’ve tried to use the following pattern: "\"" ~~ ___ ~~ "by" ~~ ___ ~~ "\"" which only matches something with " and tried to find an “or” symbol similar to regex | but to no avail.

Question: What symbols / tools can I use to develop a pattern which matches the above cases?

Question: What is the “correct” translation from a regex approach to a Mathematica approach? Are they the same?

String Pattern to match “x by y”

I’m trying to create a string pattern which will match either (with quotes included):

  • “x by y”
  • x by y
  • ‘x by y’

I’ve tried to use the following pattern: "\"" ~~ ___ ~~ "by" ~~ ___ ~~ "\"" which only matches something with " and tried to find an “or” symbol similar to regex | but to no avail.

Question: What symbols / tools can I use to develop a pattern which matches the above cases?

Question: What is the “correct” translation from a regex approach to a Mathematica approach? Are they the same?

Why match the background color when shooting to the one that is going to be used in the final presentation when the subjects will be cut out anyways?

In this (Corporate Portraiture Advice) question the photographer explains that he/she is going to use a white background when photographing coorporate portraits even when the final presentation would have the subjects against black, the idea was to cut them out from the background in post.

In some of the answers and comments people objected rather strongly to this use of white background when final presentation would be on black, arguing rather for a black background.

Why is that? Why should a black background be preffered?

My initial thinking when reading the question was that if enough light spilled on the background it would be compleatly blown out thus making the cutting out trivial.

Why this shell regular can’t match

I don’t know Why this shell regular (Line 2) can’t match, who can give official links to explain this?

$   str="origin/HEAD -> origin/master" $   if [[ $  str =~ '*origin\/HEAD*' ]] ; then echo OK ; fi # why can't work ??? $   if [[ $  str =~ .*origin\/HEAD.* ]] ; then echo OK ; fi OK $   reg='.*origin\/HEAD.*' $   if [[ $  str =~ $  reg ]] ; then echo OK ; fi # what's different of Line 2 ??? OK 

How to spot or match the specific sector of the DVD disc in the movie?

VSO Inspector Result

I’ve been checking the condition of DVD discs with VSO Inspector. Most of time, it doesn’t show any errors on the discs. However, when there’s an error on a disc, sometimes it shows that there’s an error in the beginning of the sectors and sometimes at the end of the sectors.

My question is, how can I find these sectors in the movie? As you can see in the attached photo, there’s a reading error starting from the sector 29152 in total of 3782560 Sectors (7.21 GB). Would it be beginning of the movie or at the end of the movie? How can find the exact time of the sector in the movie? I would like to check what’s actually happening in the movie at a specific time which matches to the failed sector.

Should Android kernel version date match the release date?

In the process of checking the settings on my Sony Xperia XA I came across the Linux Kernel information. Version 3.18.35 was released in June 2016 but the date shown is from 2017:

3.18.35+ BuildUser@BuildHost #1 Fri Sep 15 05:31 CST 2017 

Is it normal for the date shown here to be later than the release date? I assume it may represent the last automatic update. Also, what does the + sign mean next to the version number?.

I have no idea what BuildUser@BuildHost is but I am hoping someone can reassure me that it is normal for Sony phones 🙂

Excel – INDEX MATCH MATCH with a twist

Greetings Super Users!

I’m trying to assist some local firefighters make a crewing display page on their excel roster. Their roster is setup with dates from 1st January -> 31st December vertically in column A with the names of each firefighter across the top in Row 1. They then fill out which role any given person is working within the matrix.

On the display page they will have a section for each fire truck and want to display who is the driver for Truck 1, who is the pump operator for Truck 2 etc etc.

Now I’m familiar with using INDEX MATCH MATCH for finding a row and column and then return the intersecting value. However in this case I need to find the date (vertically) then find the role on the same row as the found date (e.g. “Truck 1 Driver”) and then return the column header (Name of firefighter perforing that role on that day)

I’m very capable with VBA but I would like to avoid using it if I can achieve the same result with a forumla. Unfortunately my formulas skills are lacking as I usually just use VBA.

How to look up by “backward match” in Dictionary.app on macOS

Dictionary.app on macOS can look up words forward match now. Can we look up items by backward match in Dictionary.app?

(If I’m allowed to wish so much, I would like to do that by “middle match”, too.)

The image here is an example of forward match. If you can do backward match, you will get something magical, for example.

here is an example of forward match