V*E 发帖数: 1642 | 1 November 23, 2010: Stable/legacy release Postfix 2.7.2, 2.6.8, 2.5.11, and 2
.4.15.
June 8, 2010: Stable release Postfix 2.7.1.
June 8, 2010: Legacy release Postfix 2.6.7.
March 23, 2010: Legacy releases Postfix 2.6.6, 2.5.10 and 2.4.14.
February 13, 2010: Stable release Postfix 2.7.0.
August 28, 2009: Stable release Postfix 2.6.5.
August 28, 2009: Legacy releases Postfix 2.5.9, 2.4.13 and 2.3.19.
August 26, 2009: Stable release Postfix 2.6.4 (withdrawn).
August 28, 2009: Legacy releases Postfix... 阅读全帖 |
|
E*V 发帖数: 17544 | 2 kao,
let me describe some basic steps
1. set /etc/conf.d/hostname
2. check /etc/hosts, make sure there are no conflicts
3. emerge postfix # install postfix
4. edit /etc/postfix/main.cf
After postfix is installed, it's time to configure it. Change the
following options in /etc/postfix/main.cf. Remember to replace $variables
with your own names.
Code Listing 2.2: /etc/postfix/main.cf
myhostname = $host.domain.name
mydomain = $domain.name
inet_interfaces = all
mydestination = $myhostname, loca |
|
b*****n 发帖数: 143 | 3 Postfix evaluation 的经典解法是把数字放到堆栈里,遇到算符就把最上面的两个数
字拿出来做计算,再把结果放进堆栈,以此类推,直到结束。
还有一个从右往左扫描的递归解法:
// 假设postfix数字只有一位
double eval_postfix(const string& postfix, size_t& idx) {
char c = postfix[idx];
if (c == '+' || c == '-' || c == '*' || c == '/') {
double right = eval_postfix(postfix, ++idx);
double left = eval_postfix(postfix, ++idx);
return calc(left, c, right);
}
else
return c - '0';
}
既然堆栈的解法是从左往右扫描,有没有从左往右的递归解法? 大家讨论讨论。 |
|
s********e 发帖数: 4064 | 4 1、postfix发信OK
可以用telnet发信,从其他计算机也可以,可以发到外部邮箱。
2、postfix本机收信OK
发给local用户的信都可以读,Maildir可用
3、imap OK
courier-imap装了,可以telnet到143端口,login, 可以用我手机的客户端收信。但是不能发,relay error 554
4、postfix不能收外部邮件
Errorcode:550 invalid address
Technical details of permanent failure:
Google tried to deliver your message, but it was rejected by the recipient
domain. We recommend contacting the other email provider for further
information about the cause of this error. The error that the other server
returned was: 550 550 阅读全帖 |
|
E*V 发帖数: 17544 | 5 easy to configure
easy to use
Please follow this howto (actually if you only need postfix to deliver
emails,
you only need the first half)
http://www.gentoo.org/doc/en/virt-mail-howto.xml
you just fake any domain name
if you only need it for yourself
but for a public mail server you need a real one.
but, who needs a public one! |
|
t***s 发帖数: 4666 | 6 as magical as postfix is, it sill cannot get around port 25 blocking. |
|
V*E 发帖数: 1642 | 7 Postfix Announcements
January 20, 2011: Postfix stable release 2.8.0. |
|
S*A 发帖数: 7142 | 8 我觉得设计是比 sendmail 好, sendmail 的蝌蚪文都是神马东西。
我以前还手动改过蝌蚪文来着。
但是 postfix 多年没有人 maintain 了,distro 不爱用没有人 maintain
的东西。 |
|
|
l*******G 发帖数: 1191 | 10 Do you have fixed IP?
Do you have FQDN?
In your postfix set up, you should give FQDN to your server name. Otherwise,
google mail server won't find your machine. |
|
l*******G 发帖数: 1191 | 11 Your myhostname in /etc/postfix/main.cf should be yourdomain.com instead of
mail.yourdomain.com
also your myorigin should be yourdomain.com
same as contents of /etc/mailname should be yourdomain.com |
|
j**7 发帖数: 143 | 12 第三题的答案:
public class InfixToPostfix {
/**
* @param args the command line arguments
*/
public static void main(String[] args) {
// TODO code application logic here
String infix="4*((5+6)*7";
infix="3+(1*2)";
String postfix=toPostfix(infix);
System.out.println(postfix);
System.out.println(evaluate(postfix));
}
//evaluate a postfix equation
static int evaluate(String postfix)
{
Stack st=new Stack阅读全帖 |
|
x****a 发帖数: 1229 | 13 在新建的stack中,调用generic method
public E remove()方法出错。如果把E改成char,运行成功。请解惑。谢谢
/**********************************************************************
作业是实现infix, postfix互换,读取string input,把数字push to a stack,遇到
括号再pop。
要求stack必须用doublyLinkedList形式生成,就是先建DoublyLinkedList class, 再
创建stack class: DoublyLinkedList stack = new DoublyLinkedList;再创
建新class 里有infix to postfix 和 postfix to infix两个method。
我两个method里,infix to postfix, 用stack1; postfix to infix
用stack2。
there i... 阅读全帖 |
|
s*****l 发帖数: 2041 | 14 【 以下文字转载自 Linux 讨论区 】
发信人: sonhill (瘦石), 信区: Linux
标 题: 真心请教关于mail server的问题
发信站: BBS 未名空间站 (Sun Sep 20 03:01:32 2015, 美东)
用Debian 7.0建了一个mail server, postfix&dovecot,
按照这里的步骤:https://www.linode.com/docs/email/postfix/email-with-postfix
-dovecot-and-mysql
现在收发邮件都没有问题。也就是说在用gmail给server发信都能收到,从server也能
正常发出邮件。
现在的问题是:
1、我想在gmail里,"settings", "accounts and import", "Send mail as",设置一
个我mail server的邮件地址。设置的时候,需要server的smtp信息。应该怎么填啊?
比方说我的邮件地址是[email protected]
/* */。我的smtp应该天myweb.com?在哪里设置的... 阅读全帖 |
|
x****a 发帖数: 1229 | 15 // public void postfix (String input)
// {
// Stack s1 = new Stack();
// String output = "";//to store the postfix expression
//
// for (int i =0; i
// {
// //get the single letter
// char letter = input.charAt(i);
//
// //convert infix to postfix
// if (letter =='1'||letter =='2'|| letter =='3'||letter =='4'||
letter =='5'||letter =='6'||
// letter =='7'||le... 阅读全帖 |
|
s*****l 发帖数: 2041 | 16 用Debian 7.0建了一个mail server, postfix&dovecot,
按照这里的步骤:https://www.linode.com/docs/email/postfix/email-with-postfix
-dovecot-and-mysql
现在收发邮件都没有问题。也就是说在用gmail给server发信都能收到,从server也能
正常发出邮件。
现在的问题是:
1、我想在gmail里,"settings", "accounts and import", "Send mail as",设置一
个我mail server的邮件地址。设置的时候,需要server的smtp信息。应该怎么填啊?
比方说我的邮件地址是[email protected]
/* */。我的smtp应该天myweb.com?在哪里设置的
smtp信息?
2、装了SquirrelMail,但是登录的时候提示出错:
ERROR: Connection dropped by IMAP server.
这是什么问题?
哪位帮忙解决了问题的,重金酬谢! |
|
h*****f 发帖数: 248 | 17 【 以下文字转载自 JobHunting 讨论区 】
发信人: henrysf (Henry), 信区: JobHunting
标 题: Re: L 电面
发信站: BBS 未名空间站 (Thu Oct 18 01:46:20 2012, 美东)
我写了以下的code, 之后就被拒了, 回信是说别的candidate写得比较好, 我还没看出
问题.
Additional requirements:
- The only operators you need to implement are +, -, *, and /.
However, your implementation should make it relatively easy to
add more operators.
- The calculator should accept floating point numbers and output
floating point numbers (i.e. when the input is 2 3 / the result
is 0.66667).
- ... 阅读全帖 |
|
p**o 发帖数: 3409 | 18
You may define the precedence levels for operators. E.g.,
precedence = {
'(': 0, ')': 0,
'+': 1, '-': 1,
'*': 2, '/': 2, '//': 2, '%': 2,
'^': 3, '**': 3,
}
operators = set(precedence.iterkeys())
right_associative_ops = {'^', '**',}
def infix_to_postlist (infix):
""" Simplified Shunting-yard algorithm. E.g.,
30 + 4 * 2 / ( 1 - 5 ) ^ 2 ^ 3
<==> 30 + ((4 * 2) / ((1 - 5) ^ (2 ^ 3)))
<==> 30 4 2 * 1 5 - 2 3 ^ ^ / +
"""
postlist = []
opstack = ... 阅读全帖 |
|
y*c 发帖数: 904 | 19 好难。
Calculator 是不是实现 infix->postfix 然后从postfix evaluate? |
|
c********2 发帖数: 56 | 20 面的是Associate C++ Developer,下面是面试题,光顾着记题了,最后只有56%的通过
率,要到
80%才能ONSITE,算是帮大家做点贡献吧,他家在招人,赶快去投简历
1) #include
using namespace std;
struct A{
A(int value) : m_value(value){}
int m_value;
};
struct B:A {
B(int value):A(value){}
};
int main(){
try {
try{
throw B(5);
}
catch(A a){
a.m_value *=2;
throw;
}
catch(B b){
b.m_value -=2;
throw b;
}
}
catch(A a){
... 阅读全帖 |
|
H***e 发帖数: 476 | 21 第一题,
operator用stack(A), 数字的不用,就用array(B)
第一步,转化成postfix,
遇到数字,直接写进B,
遇到括号,左括号push进A,右括号pop A until found 右括号,括号本身不放进B
遇到operator,pop A and write popped的元素到B, 这个pop什么时候停呢?只到你看
见一个operator having lower priority
当得到postfix后,就好办了,再用一个stackC处理B
遇到数字写进去C,遇到operator,连续从C pop出两个数字用operator算结果,再push
进C
最后就是结果
我知道很费解,很难说
规则大概就是这样,可以去网上查查。
计一 |
|
s******n 发帖数: 3946 | 22 他的意思是假设是operator重载
++i先做++再放在stack上,i++则先复制一份copy到stack上再做++,多了一份复制(假
设编译无优化)
大家看有道理吗?
I did a real test on arm compiler turn off optimization:
the O0 code is exactly the same, except that post operator++()(int dummy)
has an extra dummy parameter which is required by c++ to identify the
difference of prefix and postfix.
2nd, even I change the Test& operator++() into Test operator++(), it still generates the same code.
printf("%d \n", 10+ (abc++).value);
sub r3, fp, #8
mov r0, ... 阅读全帖 |
|
s******n 发帖数: 3946 | 23 the O0 code is exactly the same, except that post operator++()(int dummy)
has an extra dummy parameter which is required by c++ to identify the
difference of prefix and postfix.
2nd, even I change the Test& operator++() into Test operator++(), it still generates the same code.
printf("%d \n", 10+ (abc++).value);
sub r3, fp, #8
mov r0, r3
mov r1, #0 --> the dummy parameter of postfix
bl _ZN4TestppEi
mov r3, r0
ldr r3, [r3, #0... 阅读全帖 |
|
l***i 发帖数: 1309 | 24 It is easier if you use postfix or prefix notation, then you have no ( ) to
deal with, 3 operators and 4 operands, 7! is small
just write eval_postfix() and in the function check whether it is a valid
postfix or not |
|
e****e 发帖数: 418 | 25 写了一个infix to postfix,实现起来简单, 不知道思路还真不好想,面试的时候我肯
定想不出来。逆波兰表达式(postfix)evaluation是常见题,我就不贴了.
public List toPostfix(String[] in) {
List pf = new ArrayList();
Stack stack = new Stack();
for ( String s : in ) {
int p = getPrecedence( s );
if ( p == 0 )
pf.add( s );
else if ( stack.empty() )
stack.push( s );
else {
while( !stack.isEmpty() && getPrecedence( stack.peek() ) >= p )
pf.add( ... 阅读全帖 |
|
e****e 发帖数: 418 | 26 写了一个infix to postfix,实现起来简单, 不知道思路还真不好想,面试的时候我肯
定想不出来。逆波兰表达式(postfix)evaluation是常见题,我就不贴了.
public List toPostfix(String[] in) {
List pf = new ArrayList();
Stack stack = new Stack();
for ( String s : in ) {
int p = getPrecedence( s );
if ( p == 0 )
pf.add( s );
else if ( stack.empty() )
stack.push( s );
else {
while( !stack.isEmpty() && getPrecedence( stack.peek() ) >= p )
pf.add( ... 阅读全帖 |
|
j**7 发帖数: 143 | 27 第三题应该用stack把infix expression转换成一个postfix expression,然后用stack
计算postfix expression. |
|
z******g 发帖数: 271 | 28 It's easy to confuse operator precedence with order of evaluation. Operator
precedence only decides how operators match with operands, not the order
they are evaluated.
You are correct that the precedence of postfix is higher than dereference.
But that only tells you *d++ should be *(d++) but not (*d)++. This does not
conflict with the fact that postfix is evaluated after the statement.
Hope that helps. |
|
c******n 发帖数: 4965 | 29 多谢
那个prefix polish notation expression evaluation 你怎么做的?
infix 超难, postfix 很简单, refix 看一眼觉得很难, 但con右边scan 基本跟
postfix 差不多
onsite |
|
t*******r 发帖数: 22634 | 30 好吧,我解释一下,当然我时间有限,只能快速解释。
中文和英文的自然语言数字表达,这方面没有官方的说法,但从概念上
讲,可以认为是一种 multiplication & addition system。
具体来说,可以姑且认为
(1) “一二三四 one two three four twelve” 等等这种算成
一类基本 token(基本数字)。
(2)“十 百 万 hundred thousand million” 这种算另一种
token(postfix operator)。
(3)把一个数字里所有东西加起来。
(4)规则,每一级的 postfix operator 从大到小排。。。等等
坑爹的自然语言规则。
其实说白了,你用 Lex Yacc 按照 LR 文法分析器要求,写一个
从自然语言数字到阿拉伯数字的 converter,你就明白,英语和
汉语数字的差别,比 “non-positional notation system”
vs “positional notation system” 的差别,小太多了。
如果不了解 lex yacc 以及 LR 文法,或者 formal ... 阅读全帖 |
|
t*******r 发帖数: 22634 | 31 自然语言里,你所谓的 place 是 rule,只表达输入 legal 或者 illegal。。。
其实那个不应该叫 place,应该叫 order。。。你必须符合自然语言语法的 order
要求,不符合 order 要求的统统认为 illegal 而 reject 掉。
而自然语言里,是三十、还是三百、还是三万,取决于 postfix operator 是
十还是百还是万。。。并不取决于 place。。。
另外之所以叫 “十二”,不叫“一十二”,自然语言固有的 rule/convention。
这个“一”必须被省略。。。如果写 lex/yacc,碰到 postfix operator 前
是空的情况,自动设 1 就完事了。。。 |
|
d***s 发帖数: 7683 | 32 This is the Postfix program at host fbr02.csee.onr.siteprotect.com.
I'm sorry to have to inform you that your message could not be
be delivered to one or more recipients. It's attached below.
For further assistance, please send mail to
If you do so, please include this problem report. You can
delete your own text from the attached returned message.
The Postfix program
: [navy.seal]: Name or service not known |
|
|
s***a 发帖数: 1676 | 34 DNS不知道,但是postfix不用自己安装,你试试
sudo postfix start
就知道了 |
|
d******8 发帖数: 2191 | 35 按照刘川枫私信提供的postfix解决了问题,原来是/etc/mailname改了没用,在/etc/
postfix/main.cf里把mydestinantion的nymovein.com值去掉后就行了。特此感谢刘川
枫大牛,祝offer多多。 |
|
v*****r 发帖数: 1119 | 36 The configuration on relay part should be very similar whether postfix or
sendmail, though I never try on postfix. |
|
m*t 发帖数: 7490 | 37 我在ubuntu下用postfix遇到和楼主同样的问题
我有注册的domain,有固定ip
postfix按照ubuntu wiki上的设置配置起来的
现在的状况是在别的机器上用客户端软件(如thundermail等)发信一切正常,server
的应答没任何问题,但是就是信发布出去,收信人收不到
对domain端的配置不了解,仅仅将mail server的ip指向自己的server,不知道够不够
。看来还要再学习啊 |
|
|
v*****r 发帖数: 1119 | 39 To be exact, gentoo rules on documenting the DIY procedures :-> |
|
|
E*V 发帖数: 17544 | 41 yes.
actually, after I installed and made it work. never used it.... |
|
wy 发帖数: 14511 | 42 in mac, working out of box |
|
E*V 发帖数: 17544 | 43 gentoo is not built that way
you do everyting by yourself....
first you need to compile it |
|
t***s 发帖数: 4666 | 44 what's the point of change it if the world is listening on 25? |
|
|
t***s 发帖数: 4666 | 46 this exactly the real issue. |
|
m******t 发帖数: 2416 | 47
If your isp won't unblock port 25, and you don't want to use their smtp
server, the only way out for you is find an smtp server that will relay for
you
and accepts alternate smtp submission on port 587, which is normally
not blocked by isps. |
|
s*****l 发帖数: 2041 | 48 按照这个办法,已经设置好postfix, dovecot:
https://www.linode.com/docs/email/email-with-postfix-dovecot-and-mysql
(1)现在的问题是怎么查email?在那里看email啊?我试着装了squirrelmail,但是
似乎
两者是不同的系统。我在dovecot设置的帐户/密码根本不能登录squirrelmail,又
找不到在squirrelmail哪里设置dovecot数据库信息。
(2)以前的版本,我可以很方便的使用/etc/aliases,但是这个新的方法似乎/etc/
aliases不管用。
(3)此外,email帐户和server的user似乎是分开的。例如我在mydomain.com有用户
myuser,如果发信给[email protected]
(function(){try{var s,a,i,j,r,c,l,b=document.getElementsByTagName("script");l=b[b.length-1].previousSibling;a=l.getAttribute... 阅读全帖 |
|
z****e 发帖数: 2024 | 49 class Number {
public:
Number& operator++ (); // prefix ++
Number operator++ (int); // postfix ++
};
why should the prefix version returns by reference, the postfix version by
value? why not both by reference? |
|
t****t 发帖数: 6806 | 50 The reason is A::f is a member template. Otherwise it is ok.
[Standard 14.2]
4 When the name of a member template specialization appears after . or -> in
a postfix-expression, or after nested-name-specifier in a qualified-id, and
the postfix-expression or qualified-id explicitly depends on a template-
parameter (14.6.2), the member template name must be prefixed by the keyword
template. Otherwise the name is assumed to name a non-template. [Example:
class X {
public:
template X* alloc(... 阅读全帖 |
|