The UNIX and Linux Forums  
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.

Go Back   The UNIX and Linux Forums > Top Forums > UNIX for Dummies Questions & Answers
.
google unix.com



UNIX for Dummies Questions & Answers If you're not sure where to post a UNIX or Linux question, post it here. All UNIX and Linux newbies welcome !!

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
How to convert a single column into several rows and columns? ashton_smith UNIX for Dummies Questions & Answers 5 05-24-2008 04:44 PM
Requesting an AWK code to generate averaged rows in a column solracq Shell Programming and Scripting 8 05-05-2008 04:36 PM
convert rows into column cdfd123 Shell Programming and Scripting 3 01-11-2008 12:54 PM
splitting a column into rows spindoctor UNIX for Dummies Questions & Answers 3 07-24-2007 03:25 PM
flags to suppress column output, # of rows selected in db2 sql in UNIX jerardfjay Shell Programming and Scripting 1 11-02-2005 06:48 AM

Closed Thread
English Japanese Spanish French German Portuguese Italian Dutch Swedish Russian Norwegian Hungarian Hebrew Danish Bulgarian Greek Powered by Powered by Google
 
LinkBack Thread Tools Search this Thread Rate Thread Display Modes
  #1 (permalink)  
Old 03-21-2006
frebo frebo is offline
Registered User
  
 

Join Date: Mar 2006
Posts: 3
Factorize some rows in a column

HI!

I have a file containing a column of numbers with 69 rows.
I won’t to factorize row 20 to 50 with 1.03
How do I do that?
(I’m a beginner as you easily can understand)
  #2 (permalink)  
Old 03-21-2006
gauravgoel gauravgoel is offline
Registered User
  
 

Join Date: Dec 2005
Location: India
Posts: 218
seems like a homework question.
ok show us what you tried.
  #3 (permalink)  
Old 03-21-2006
frebo frebo is offline
Registered User
  
 

Join Date: Mar 2006
Posts: 3
As I sad, i'm a beginner

I have

list/file containing:

10
20
10
45
43
named "test.txt"

This is what I won't to do.

10
20*1,03
10*1.03
45
43

and then crerate a new file with the modified data, named "test_mod.txt"

It is an extremly simple operation (I presume).
Best Regards!
  #4 (permalink)  
Old 03-21-2006
gauravgoel gauravgoel is offline
Registered User
  
 

Join Date: Dec 2005
Location: India
Posts: 218
Hi frebo,
this really is very simple.
but it seems like a homework assignment to me.
and as per the rules of this forums this is not allowed, unless and until you have tried your best for getting the answer.
So first post what you have tried on your own,

Regards,
Gaurav
  #5 (permalink)  
Old 03-21-2006
frebo frebo is offline
Registered User
  
 

Join Date: Mar 2006
Posts: 3
this is a very strange forum

I will be back
  #6 (permalink)  
Old 03-21-2006
gauravgoel gauravgoel is offline
Registered User
  
 

Join Date: Dec 2005
Location: India
Posts: 218
a hint to work with

saying that a thing is strange is a relative term.
something strange for you may not be strange for someone else.

You are always welcome with your queries, but this forum strictly discourage any homework assignment where the aim is to get the answer without working hard for it. The proper way of learning is try it yourself first.

Now your hint,

You can use awk for it and use NR field in it.
NR is the current record number on which awk is operating.

Gaurav
Closed Thread

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




All times are GMT -4. The time now is 08:42 AM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited. Language Translations Powered by .
vBCredits v1.4 Copyright ©2007 - 2008, PixelFX Studios
The UNIX and Linux Forums Content Copyright ©1993-2009. All Rights Reserved.Ad Management by RedTyger

Content Relevant URLs by vBSEO 3.2.0