IT Questions and Answers :)

Friday, January 17, 2020

Where are you most likely to find a rubber duck used for troubleshooting?

Where are you most likely to find a rubber duck used for troubleshooting?

  • Community manager's desk
  • Datacenter infrastructure testing
  • Networking tool kit
  • Software developer's desk 
Where are you most likely to find a rubber duck used for troubleshooting?

EXPLANATION

A rubber duck in use by a developer to aid code review. In software engineering, rubber duck debugging is a method of debugging code. The name is a reference to a story in the book The Pragmatic Programmer in which a programmer would carry around a rubber duck and debug their code by forcing themselves to explain it, ... It referenced rubber ducking as a powerful method for solving



Share:

What is the difference between a bit and a byte?

What is the difference between a bit and a byte?

  • They are the same.
  • A byte is 256 bits.
  • A byte is eight bits.
  • One measures bandwidth, the other throughput. 


EXPLANATION

Actually no, there's a big difference between a bit and a byte. A byte is much bigger — eight times bigger, to be exact, with eight bits in every byte. By extension, there are eight megabits in every megabyte, and one gigabyte is eight times bigger than one gigabit.

Share:

Thursday, January 16, 2020

Which of the following characters are the MOST efficient to use for a comment line when writing DOS batch files?

Which of the following characters are the MOST efficient to use for a comment line when writing DOS batch files?

  • **
  • ::
  • REM
  • ##


EXPLANATION

 :: is essentially a blank label that can never be jumped to, whereas REM is an actual command that just does nothing. In neither case (at least on Windows 7) does the presence of redirection operators cause a problem.
However, :: is known to misbehave in blocks under certain circumstances, being parsed not as a label but as some sort of drive letter. I'm a little fuzzy on where exactly but that alone is enough to make me use REM exclusively. It's the documented and supported way to embed comments in batch files whereas :: is merely an artifact of a particular implementation.

Here is an example where :: produces a problem in a FOR loop.
This example will not work in a file called test.bat on your desktop:
@echo off
for /F "delims=" %%A in ('type C:\Users\%username%\Desktop\test.bat') do (
    ::echo hello>C:\Users\%username%\Desktop\text.txt
)
pause
While this example will work as a comment correctly:
@echo off
for /F "delims=" %%A in ('type C:\Users\%username%\Desktop\test.bat') do (
    REM echo hello>C:\Users\%username%\Desktop\text.txt
)
pause
The problem appears to be when trying to redirect output into a file. My best guess is that it is interpreting :: as an escaped label called :echo.
Share:

What does "IT" stand for?

What does "IT" stand for?

  • Internet Technology
  • Information Technology
  • Information Transport
  • Information Techno 

EXPLANATION

Information technology is the use of computers to store, retrieve, transmit, and manipulate data or information. IT is typically used within the context of business operations as opposed to personal or entertainment technologies. IT is considered to be a subset of information and communications technology.


Share:

If two hosts are connected to a single four port network hub with separate cables, how many collision domains are there?

If two hosts are connected to a single four port network hub with separate cables, how many collision domains are there?

  • 4
  • 3
  • 1
 If two hosts are connected to a single four port network hub with separate cables, how many collision domains are there?

EXPLANATION

collisions are a normal characteristic of networks. You cannot stop all collisions from occurring, as that would be unrealistic. A better goal is to try to minimize that number of collisions that take place. To do so, you need to divide your Ethernet segment into smaller collision domains, which will result in fewer hosts per collision domain. To accomplish this, you have to use a switch. Every switchport has its own collision domain. This means that if you connect, for example, four hosts to four different switchports, you will have four collision domains


Share:

Popular Posts