By admin | April 24, 2005
List the files in current directory sorted by size ? - ls -l | grep ^- | sort -nr
List the hidden files in current directory ? - ls -a1 | grep "^\."
Delete blank lines in a file ? - cat sample.txt | grep -v ‘^$’ > new_sample.txt
Search for a sample string in particular files [...]
Also posted in General, Networking |
By admin | March 11, 2005
What arguments do you frequently use for the Perl interpreter and what do they mean?
What does the command ‘use strict’ do and why should you use it?
What do the symbols $ @ and % mean when prefixing a variable?
What elements of the Perl language could you use to structure your code to allow for maximum [...]
How do you take a single line of input from the user in a shell script?
Write a script to convert all DOS style backslashes to UNIX style slashes in a list of files.
Write a regular expression (or sed script) to replace all occurrences of the letter ‘f’, followed by any number of characters, followed by [...]
By admin | January 17, 2005
What are the basic functions of an operating system? - Operating system controls and coordinates the use of the hardware among the various applications programs for various uses. Operating system acts as resource allocator and manager. Since there are many possibly conflicting requests for resources the operating system must decide which requests are allocated resources [...]
Also posted in Hardware, Windows |
By admin | September 1, 2004
Advantages/disadvantages of script vs compiled program.
Name a replacement for PHP/Perl/MySQL/Linux/Apache and show main differences.
Also posted in Database |
How do you list the files in an UNIX directory while also showing hidden files? ls -ltra
How do you execute a UNIX command in the background? Use the “&”.
Also posted in Database |
By admin | December 7, 2003
Q: How would you make the following SQL statement run faster? SELECT * FROM TABLEA WHERE COL1=’A’ AND COL2=’B’; A: Make sure that COL1 and COL2 have indexes.Find out which condition will return less values and use that as the first conditonal.
By admin | December 7, 2003
Question 1: What is the major advantage of a hash table? (Asked by Silicon Magic Corp. people)
Answer: The major advantage of a hash table is its speed. Because the hash function is to take a range of key values and transform them into index values in such a way that the key values are [...]
By admin | December 7, 2003
What is LILO?
LILO stands for Linux boot loader. It will load the MBR, master boot record, into the memory, and tell the system which partition and hard drive to boot from.