Skip to main content

All Questions

Tagged with
1 vote
2 answers
57 views

How to find duplicates in a text file in python and create a new text file with out them

I am trying to remove duplicates from text files to make a current process more efficient Example input: 1 1 1 1 2 1 3 1 4 1 Example Output: 1 1 2 1 3 1 4 1 my issue is when ...
Kaleb Brookshire's user avatar
0 votes
2 answers
89 views

Issue with writing to a text file in C using printf()

I'm trying to write to a file in C, so quite simple stuff. But I am encountering an issue with the below code: #include<stdio.h> #include<stdlib.h> int main() { FILE *fptr; int ...
Owl's user avatar
  • 3
1 vote
4 answers
48 views

How do we select only particular word in bash?

I have this output from a cli - host-0 ec: 0 kafka_5.1.1-2_1 host-1 ec: 1 host-2 ec: 0 kafka_5.1.1-2_0 host-3 ec: 0 host-4 ec: 0 host-5 ec: 0 I want to copy & save host-0 & host-2 ...
Madhavi Deshpande's user avatar
0 votes
0 answers
13 views

I try to extract data from txt file

I have a large data file . The data which I would to extract in format GROUP NUMBER 1 N BIRTH CODE TEST 1 TEST 2 TEST 3 TOTAL ID 1 28-4-1986 ...
user1796483's user avatar
0 votes
1 answer
19 views

how to open a textgrid with Praatio when xmin = xmax

I try to open a textgrid with praatio : from praatio import textgrid tg = textgrid.openTextgrid(myfile) But in this textgrid, it happen sometimes that xmin = xmax : "intervals [11]: xmin = 3.34, ...
laure's user avatar
  • 1
-1 votes
1 answer
94 views

Combine an audio and a text file as one single file

Is there a way to combine an audio file (either .mp3 or .wav) and store some text information in a .txt file and save it as one single file (in which format such a file would be, I am not sure). Edit: ...
woka's user avatar
  • 30
1 vote
1 answer
111 views

How to get character position in a text file encode in UTF-8 in C?

The C Standard specifies that ftell() returns the position of a character from the beginning of the file when it's opened in binary mode. ... obtains the current value of the file position indicator ...
Daniel Muรฑoz's user avatar
1 vote
1 answer
71 views

Why setting file position and writing in it, fill with null char in C?

I was trying to write in a arbitrary position in a text file in C. #include <stdio.h> void write_in_file(FILE *file, char *str, fpos_t *pos){ fsetpos(file, pos); for(int i=0; str[i] != ...
Daniel Muรฑoz's user avatar
0 votes
1 answer
54 views

Ansible lineinfile - add substring only if missing

I'm trying to disable transparent_hugepage in the kernel. Which according to this article means adding the substring transparent_hugepage=never to the GRUB_CMDLINE_LINUX variable in /etc/default/grub. ...
azzid's user avatar
  • 373
0 votes
0 answers
15 views

I need a batch file to find files with specific extension and add in them one line of text

I'm completly new and dont know a thing about creating batch files. I used to study informatics but now I'm car mechanic :) I've got few computers in few places containing VMware machines that need to ...
Michaล‚ Gadomski's user avatar
1 vote
0 answers
60 views

Could someone explain this error on fprintf() in Octave?

I am trying to write in a text file the result of an integral, but when I run the program I get the next error. error: fprintf: wrong type argument 'class' Hereยดs my code. syms x f=x; archivo=fopen('...
javi009's user avatar
  • 11
-1 votes
1 answer
48 views

How can I batch-export each line of a text file as its own separate text file?

I have a text file that constitutes a "database" of Pokemon information, formatted like so: Bulbasaur ๐—š๐—ฟ๐—ฎ๐˜€๐˜€๐Ÿƒ ๐—ฃ๐—ผ๐—ถ๐˜€๐—ผ๐—ป๐Ÿงช Ivysaur ๐—š๐—ฟ๐—ฎ๐˜€๐˜€๐Ÿƒ ๐—ฃ๐—ผ๐—ถ๐˜€๐—ผ๐—ป๐Ÿงช Venusaur ๐—š๐—ฟ๐—ฎ๐˜€๐˜€๏ฟฝ...
fast car's user avatar
1 vote
1 answer
120 views

Count number of integers in text file in C

I made text file called qsort.txt and wrote arbitrary many integers in file (In my case 35 integers to be precise). My goal is to count how many integers are in that file, put them into an array ...
tux's user avatar
  • 25
0 votes
0 answers
60 views

Publishing output to email and or txt file in powershell

I am trying to get the following code to either print to a text file and or print to an email so i can send out a daily update for something but I am having a whale of a time getting it to do either ...
Jr Weischedel's user avatar
0 votes
1 answer
53 views

How to create a python module that can take multiple values to look for in a txt file and return the result

I have a passwd.txt file which is formatted below and i want to create a module. this module should take each line separate it by ":" and save the 3 values, userName, realName and password ...
bobby mckeown's user avatar

15 30 50 per page
1
2 3 4 5
โ€ฆ
147