Hi
I nees answer for this questions

1.In Linux, what describes hdb2? Choose all answers that apply. Selecting an incorrect option will give minus points!

A) [-1.00] Refers to the first disk.
B) [1.00] Refers to the second disk.
C) [-1.00] Refers to hard drive number 2.
D) [1.00] Refers to the second partition.
E) [-1.00] Refers to the fourth partition on the disk

2.What is the major difference between a Windows .dll file and a .exe file?(one question is right here)
A) [0.00] The .dll file does not contain any executable code.
B) [1.00] There is no major difference.
C) [0.00] The .dll file contain mapped addresses of executable code.
D) [0.00] The .dll file contains all of the executable code for a program.

Dani AI

Generated

Brief, practical clarification (for future readers and exam-style questions).

The label hdb2 denotes "partition 2 on the second ATA/IDE-style disk" in the classic Linux device-name scheme; that makes answers B and D the intended choices. Modern kernels and drivers, however, often present ATA/SATA disks under /dev/sd* (so you may see sdb2 instead), and device-node names can change with hardware order or driver choice — do not treat /dev/hdX or /dev/sdX as immutable identifiers. (old-releases.ubuntu.com)

A few important gotchas that cause student confusion: on MBR-partitioned disks primary partitions are numbered 1–4 and logical partitions (inside an extended container) start at 5; GPT does not use extended/logical partitions (all partitions are numbered sequentially). GRUB historically used a zero-based partition index in some contexts, which is another source of off-by-one mistakes. Check partition type (MBR vs GPT) if numbers look odd. (linux-training.be)

Quick diagnostics and a robust practice to avoid name drift:

# inspect devices and partition numbers
lsblk -f
sudo fdisk -l /dev/sdb
sudo udevadm info --query=all --name=/dev/sdb2
sudo blkid /dev/sdb2

Do not hard-code /dev/sdb2 in fstab or scripts — use UUID=, PARTUUID= or the stable links under /dev/disk/by-id or /dev/disk/by-uuid so mounts survive reordering. (man7.org)

On the Windows question: .exe and .dll files share the same Portable Executable (PE) format; the practical difference is loader semantics and a flag in the PE header (an EXE is an image meant to be launched; a DLL is meant to be loaded into another process). That is why the exam answer "There is no major difference" is the intended choice, with the caveat that the loader treats them differently. (learn.microsoft.com)

Notes: gave a solid core explanation; the points above add partition-numbering nuance, kernel/driver naming changes, and commands to verify the real mapping on a live system.

Recommended Answers

All 4 Replies

i think the answers are
1=D not 100% on that one
2=A&C me thinks

i think my answers are correct but actually im just guessing .lol

The answers given by the OP are correct, that is, 1: B & D and 2: B. The explanation is as follows:

1) The Linux naming convention for hard-drives has the first two letters to identify the kind of hard-drive it is, usually "hd" for normal hard-drive and "sd" for a SATA-connected hard-drive (as opposed to the old IDE connections). The letter after that is just an alphabetic order letters to identify the drives (a: first, b: second, etc..). And then, the number is the number of the partition. Thus, hdb2 is in a "hard-drive", it is in the second physical hard-drive, and it is the second partition of that hard-drive. Thus, the answers are B and D.

2) Both a DLL and an EXE contain executable code, so, (a) is false. Both a DLL and an EXE contain mapped addresses of executable code (i.e., exported symbols, as they are usually called), so, (c) is false. And a DLL does not necessarily, and almost always not, contain all the executable code for a program, so, (d) is false. By process of elimination, (b) must be the correct answer because it is quite true that there is very little difference between a DLL and an EXE, in fact, the differences are quite trivial, just a flag that is different (to tell the OS whether it is a EXE or a DLL), and the fact that an EXE is expected to have a main() function while a DLL is expected to optionally have a DLLMain function, that's all that is different between the two. The difference is really only in the way they are used and the way they are generally loaded: executables are generally loaded on their own by the OS (to start executing a program), while a DLL is generally loaded by an existing process and is loaded into a shared address-space with that process. You can load an executable (EXE) the same way you load a DLL, and it will work. I don't know if it works to "execute" a DLL, provided that you put a main() function in it, but that wouldn't be too far from reality.

@OP: What is your question?

its back to school for me .lol and this time im gonna listen

mike_2000_17 Thank so much for your explain and thanks caperjack for you.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.