Hi All
I have written a map program. The program is simple
I have the input file input.dat which has the following
I want to map
a[BLACK]=first row ie Black 000180 and TECH1
a[BLUE ]=second row i.e BLUE 000340 and TECH2
While running the above program the output is
the whole file
BLACK 000180 TECH1
BLUE 000340 TECH2
I don;t understand when i want to print second.chr alone why it prints all?
Can any one help?
Regards
Dhanamurthy
Last edited by Yogesh Sawant; 04-14-2008 at 02:22 PM..
Reason: added code tags
Hi guys ...
i need ur help with some printing problem in unix ...
first prob. :
i wanna print from my NCR unix to an Win NT , Ip based printing server ( HP JetDirect ) .
My issue , is it possible to print directly to an Ip address from unix ?
How do i make it work to get any results ?... (3 Replies)
There is a "Map"? of Unix and all its varients somewhere on the net. I used to have the link , but can't find it now. Anyone out there have a clue????
A good magician never reveals his secret; the unbelievable trick
becomes simple and obvious once it is explained. So too with... (3 Replies)
Hi all
I have to compare maps/files on two seperate boxes and the output must be as following:
1)list the maps/file on box1
2)list the maps/file on box2
3)List maps in both the environments
a) which are same
b)which are different
pls any ideas are appreciated
thnks (2 Replies)
i just want to dump my array and see if it contains the values i am expecting. It should print as follows,
ignore=345fht
ignore=rthfg56
.
.
.
ignore=49568g
Here is the code. Is this even possible to do? please help
termReport.pl < $4 | dos2ux | head -2000 | awk '
BEGIN... (0 Replies)
Hello everyone,
Can anyone give me a suggestion on lines below:
%hash = map {($_, -M "$dir/$_")} readdir D;
print map "$_\n", sort values %hash;
The thing is this will print the floating point numbers of files recently created/modified. I'd like to print out the file names only while... (0 Replies)
We are using Red Hat. We have a issue like this: We want to print from Linux, to a printer attached to a Windows machine. What we want to print is a PDF. It prints, but the printing starts from the middle of the page. In the report, there is no space at the top but still printing starts from the... (5 Replies)
Hi,
We have a Unix 3.2v5.0.5.
I installed a printer via scoadmin, HP network printer manager with network peripheral name (hostname and ipadres are in /etc/hosts).
This is the configuration file :
Code:
root@sco1 # cat configurationBanner: on:AlwaysContent types: simpleDevice:... (0 Replies)
Is there a way to print multiple array elements without iterating through the array using bash?
Can you do something like...
echo ${array}and get all those separate elements from the array? (2 Replies)
Hello All,
I am having an issue of putting a Boolean value in the maps as the 3rd parameter. Something like the following :
int value;
std::map<String str, int x, bool bl>
where bool returns false if x>value else true.
All I see in the map examples is that I can add the... (2 Replies)
Hello Experts,
I am trying to print an array in reverse.
Input :
1. Number of array elements
2. The array.
Eg:
4
1 2 3 4
Expected Output (elements separated by a space) :
4 3 2 1
My Code : (6 Replies)
Discussion started by: H squared
6 Replies
LEARN ABOUT V7
pkopen
PKOPEN(3) Library Functions Manual PKOPEN(3)NAME
pkopen, pkclose, pkread, pkwrite, pkfail - packet driver simulator
SYNOPSIS
char *pkopen(fd)
pkclose(ptr)
char *ptr;
pkread(ptr, buffer, count)
char *ptr, *buffer;
pkwrite(ptr, buffer, count)
char *ptr, *buffer;
pkfail()
DESCRIPTION
These routines are a user-level implementation of the full-duplex end-to-end communication protocol described in pk(4). If fd is a file
descriptor open for reading and writing, pkopen carries out the initial synchronization and returns an identifying pointer. The pointer is
used as the first parameter to pkread, pkwrite, and pkclose.
Pkread, pkwrite and pkclose behave analogously to read, write and close(2). However, a write of zero bytes is meaningful and will produce
a corresponding read of zero bytes.
SEE ALSO pk(4), pkon(2)DIAGNOSTICS
Pkfail is called upon persistent breakdown of communication. Pkfail must be supplied by the user.
Pkopen returns a null (0) pointer if packet protocol can not be established.
Pkread returns -1 on end of file, 0 in correspondence with a 0-length write.
BUGS
This simulation of pk(4) leaves something to be desired in needing special read and write routines, and in not being inheritable across
calls of exec(2). Its prime use is on systems that lack pk.
These functions use alarm(2); simultaneous use of alarm for other puposes may cause trouble.
deprecated PKOPEN(3)