Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8002369
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 4, 20262026-06-04T16:20:26+00:00 2026-06-04T16:20:26+00:00

Firstly the only thing I have available is powershell. I have figured out how

  • 0

Firstly the only thing I have available is powershell.
I have figured out how to compare two arrays; however, I am having a bit if difficulty figuring out how to get the data back in the format I need.

$foo = @(100, 200 ,300 ,400 ,500 ,600 ,700 ,800 ,900 ,1000)
$bar = @(50, 100, 600 , 900)

Desired results would be an array with the following information

 50, 200, 300, 400, 500, 700, 800, 1000

Note that the like values

100, 600 , 900

are dropped and

50 

which is in the second array is added to the output.

is this possible?

thanks

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-04T16:20:28+00:00Added an answer on June 4, 2026 at 4:20 pm

    Compare-Object is your friend:

    PS C:\Users> $foo = @(100, 200 ,300 ,400 ,500 ,600 ,700 ,800 ,900 ,1000)
    PS C:\Users> $bar = @(50, 100, 600 , 900)
    PS C:\Users> Compare-Object $foo $bar -PassThru
    50
    200
    300
    400
    500
    700
    800
    1000
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Firstly, I do not have any malicious intent out of this question. I would
Firstly, when I say other browsers I really only mean Firefox because that's all
Firstly: I am totally a newbie for this kind of work. I have a
Firstly, Modifying may be the wrong term, I see a few people have posted
Hi i have a couple of question about using named pipes. Firstly, when trying
I found strange thing. For example I have Order and Item entity. Item is
Firstly, this DB question could be a bit DB agnostic, but I am using
Since I am new to iOS development I have a few Questions. Firstly I
We have a requirement to prevent saving additional copies of PDFs that exist out
Firstly, there have some tag links in my main page. click each one, post

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.