Title: Array Intersection in Bash - Runnable Code Snippet
Open Graph Title: Array Intersection in Bash - Runnable Code Snippet
X Title: Array Intersection in Bash - Runnable Code Snippet
Description: Find common elements that exist in both arrays. Runnable Bash snippet with live execution.
Open Graph Description: Find common elements that exist in both arrays. Runnable Bash snippet with live execution.
X Description: Find common elements that exist in both arrays. Runnable Bash snippet with live execution.
Keywords:
Opengraph URL: https://tempercode.dev/snippets/array-intersection-bash
Domain: tempercode.dev
{"@context":"https://schema.org","@type":"SoftwareSourceCode","name":"Array Intersection","description":"Find common elements that exist in both arrays.","programmingLanguage":"Bash","text":"echo \"$arr1\" | jq --argjson b \"$arr2\" '[.[] | select(. as $x | $b | index($x))]'"}
| theme-color | #0c0d12 |
| color-scheme | dark |
| author | Temper |
| creator | Temper |
| publisher | Temper |
| og:image | https://tempercode.dev/og-image.png |
| og:type | article |
| twitter:card | summary_large_image |
| twitter:image | https://tempercode.dev/og-image.png |
Links:
Viewport: width=device-width, initial-scale=1