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 984639
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 16, 20262026-05-16T05:02:51+00:00 2026-05-16T05:02:51+00:00

If I have some array element, how can I get individual numbers from the

  • 0

If I have some array element, how can I get individual numbers from the array element buffer[0]?

For example, suppose I have buffer[0]=0x0605040302, I’d like to first extract 2, then 0, then 6, etc.

  • 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-05-16T05:02:52+00:00Added an answer on May 16, 2026 at 5:02 am

    The array element content is ONE number. You are trying to extract A DIGIT out of it. Look for masking and shifting – the & and >> operators.

    EDIT:

    A mask is a string of “0”s and “1”s that let you isolate bits of interest out of a number. A mask containing the hex digit 0xF is used to isolate individual hex digits in a number. For example:

    num = 0x4321 (= 0100_0011_0010_0001)
    mask = 0x00f0 (= 0000_0000_1111_0000)
    num & mask = 0x0020 (= 0000_0000_0010_0000)

    Shifting a number effectively brings the required bit to a required position in a number. So, shifting a number to the right by n positions will bring bit #n to place #0.

    num = 0x4321 (= 0100_0101_0010_0001)
    num >> 8 = 0x0043 (= 0000_0000_0100_0011)

    Combine the two operations and you have your extracted digit!

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Ask A Question

Stats

  • Questions 532k
  • Answers 531k
  • Best Answers 0
  • User 1
  • Popular
  • Answers
  • Editorial Team

    How to approach applying for a job at a company ...

    • 7 Answers
  • Editorial Team

    How to handle personal stress caused by utterly incompetent and ...

    • 5 Answers
  • Editorial Team

    What is a programmer’s life like?

    • 5 Answers
  • Editorial Team
    Editorial Team added an answer Cascading Stylesheets only go (cascade) down, so they're not designed… May 17, 2026 at 12:02 am
  • Editorial Team
    Editorial Team added an answer .... JOIN .... ON t1.col ILIKE '%' || t2.col ||… May 17, 2026 at 12:02 am
  • Editorial Team
    Editorial Team added an answer If you deploy using iTunes via downloading from the App… May 17, 2026 at 12:02 am

Trending Tags

analytics british company computer developers django employee employer english facebook french google interview javascript language life php programmer programs salary

Top Members

Related Questions

So I have some code here that takes user input from a standard web
This is a really basic question but... I have some code like this var
I have some input fields like below: <input type=text name=date_1 class=dataList value=2009-12-30 /> <input
I have some String[] arrays, for example: ['a1', 'a2'] ['b1', 'b2', 'b3', 'b4'] ['c1']
I know individual attributes can be retrieved with the attr() method, but I'm trying
I have been trying for hours to figure this out. I have some JSON
Suggestions other that dumping IE6 that is... I can't control that :) Quick synopsis
I am using the __call magic within some of my mvc code to produce
I've got an odd problem with a WPF Calendar control. I have modified the
I was noticing some curious behavior with Perl's split command, particularly in cases when

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.